All Collections
API & Webhooks
Scheduled report API
Scheduled report API

Schedule an audit to be generated in the future, optionally on a recurring basis

Andrew Waite avatar
Written by Andrew Waite
Updated over a week ago

This page explains how to use our API to schedule website reports in Insites.


Schedule a business report

Method: POST

Request body should be JSON encoded, and can include the following fields:

Property

Definition

Example

run_date

String – The UTC formatted date on which the report should run

2019-11-30T13:30:00

repeat_runs

Boolean – Determines whether the reports should be repeated at certain intervals

true

frequency

Integer – Determines the how often reports should be repeated. Required if repeat_runs is true

2

frequency_unit

String – Determines whether the frequency is in days, weeks or months.

days

stop_automatically

Boolean – Determines if the reports should stop after a certain number of repeats

true

repeats_remaining

Integer – Determines how many repeats should be executed. Required if stop_automatically is true

3

notify_contacts

Boolean – Determines if a notification email should be sent when a scheduled report completes

true

notification_emails

JSON encoded string – Specifies the email addresses which will be notified if notify_contacts is true

[{text:”name@email.com”}]

notification_medium

String – Determines whether the report should be shared as a pdf or a link

pdf

Expected response

If successful, you would expect a 200 response.


Retrieve a business report schedule

Method: GET

Expected response

If successful, you would expect a 200 response, with a body like this:

{
"status": "success",
"schedule": [SCHEDULE DATA]
}
Did this answer your question?