Create a report schedule
POST /site_reports/schedules
Description
Creates a scheduled report for a site.
Reports can be scheduled to run monthly, weekly or every two weeks. To run a report on a monthly basis, set the Unit to MONTHLY and set the Frequency Value to the day of the month you want the report to be run every month. For example, Unit = MONTHLY and Frequency Value = 15 will run the report on the 15th of every month. Note: if you set a report to run on the 29th, 30th or 31st of the month and that date doesn’t occur in the given month, the report will run on the last day of the month. For example, if you designate the 31st of the month, the report will run on the last day of February. You can run reports on a weekly or every two week basis by setting the Unit to DAYS and then setting the Frequency Value to 7 for weekly reports or 14 for reports to run every two weeks. The day of the week is determined by the next_scheduled_date value. For example, if the next_scheduled_date value is a Tuesday and the Frequency Value is 7, then the report will run each week on Tuesday.
Authorizations
Section titled “Authorizations ”Request Body
Section titled “Request Body ”object
ID of the site to schedule reports for
Example
00000000-0000-0000-0000-000000000000Title for the scheduled report
Example
Monthly Site Performance ReportISO 8601 datetime for the first report generation
Example
2025-02-01T00:00:00.000ZUUID of the report template to use
Example
123e4567-e89b-12d3-a456-426614174000Report generation frequency. For DAYS, set value to 7 (weekly) or 14 (biweekly). For MONTHLY, set value to the day of the month (1-31).
object
Frequency value. For DAYS, value is 7 or 14. For MONTHLY, value is the day of the month (1-31).
Example
7Frequency unit. ‘DAYS’ for weekly or biweekly reports, ‘MONTHLY’ for monthly reports.
Example
DAYSList of recipients for the scheduled report
object
Example
John DoeExample
john@example.comSections to include in the report. Valid section names depend on the template
(e.g. cover, overview, usage, themes). Use GET /site_reports/templates
to discover available sections for a given template.
object
Example
coverResponses
Section titled “ Responses ”Created.
Note: the response contains only a confirmation message. To retrieve the created schedule and its UUID, use the site reports schedules listing endpoint.
object
Example
Schedule created successfullyBad Request
object
A message regarding the error that occurred on the server
Example
Invalid Site: Name cannot be empty.(Optional) A URL where documentation regarding this specific error can be found
An array of error objects describing specific errors that arose when servicing the request
object
The name of the resource that was being processed when the error occurred
Example
Site(Optional) The specific field associated with the error
Example
name(Optional) A type associated with the error. invalid_value, access_error, value_unavailable
Example
invalid_value(Optional) A machine code relating to the error that occurred with the field and resource
Example
too_long(Optional) A human-readable message relating to the error that occurred with the field and resource
Example
Name is too long (maximum is 40 characters)Authentication Error
object
A message regarding the error that occurred on the server
Example
Bad Credentials(Optional) A URL where documentation regarding this specific error can be found
Not authorized
object
A message regarding the error that occurred on the server
Example
You don't have permission to perform that action(Optional) A URL where documentation regarding this specific error can be found
Not found
object
A message regarding the error that occurred on the server
Example
Not Found(Optional) A URL where documentation regarding this specific error can be found
Too many requests
Internal Server Error
object
A message regarding the error that occurred on the server
Example
An unexpected error occurred, please try again in a few minutesAn invalid response was received from an upstream server
Service unavailable