Skip to content

Depot reportschedules

Registers the delivery routes on the TENANT mux.

This page is generated from the Depot route table. Every operation carries the permission it needs and the anchor an agent can link to.

GETreport:readtenant facehosteditmspremoteIdempotent

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

List report schedules

NameInTypeRequiredDescription
dirquerystring, one of asc, descNoSort direction.
pagequeryintegerNoOne-based page number. Defaults to 1.
pageSizequeryintegerNoRows per page, 1 to 200. Defaults to 50.
qquerystringNoFree-text search term.
sortquerystring, one of created, enabled, last, name, nextNoSort key.
StatusBodyDescription
200application/json, PagedResultReportScheduleViewSuccess.
400application/problem+json, ProblemDetailsOne or more validation errors occurred.
401application/problem+json, ProblemDetailsNo signed-in identity.
403application/problem+json, ProblemDetailsThe identity does not hold report:read.
500application/problem+json, ProblemDetailsNo client store in request context.

200 response body

FieldTypeDescription
itemsrequiredarray of ReportScheduleView
items[].cannedReportstring
items[].createdAtrequiredstring (date-time)
items[].createdByUserIdstring
items[].cronExprrequiredstring
items[].definitionIdstring
items[].enabledrequiredboolean
items[].graceSecondsrequiredinteger
items[].lastRunAtstring (date-time) or null
items[].missedRunPolicyrequiredstring
items[].namerequiredstring
items[].nextDueAtstring (date-time) or null
items[].pausedrequiredboolean
items[].pausedReasonstring
items[].publicIdrequiredstring
items[].recipientsrequiredarray of string
items[].timezonerequiredstring
items[].updatedAtrequiredstring (date-time)
pagerequiredinteger
pageSizerequiredinteger
totalrequiredinteger
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
# This operation is idempotent. Repeating it does not repeat its effect.
curl -X GET 'https://depot.example.com/api/v1/reports/schedules?dir=asc&page=0&pageSize=0&q=<q>&sort=created' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-b 'outpost_console=<console-session>'

POSTreport:scheduletenant facehosteditmspremote

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

Create report schedule

Required, sent as application/json.

FieldTypeDescription
cannedReportstring or null
cronExprstring or null
definitionIdstring or null
enabledboolean or null
graceSecondsinteger or null
missedRunPolicystring or null
namestring or null
recipientsrequiredarray of string
timezonestring or null
StatusBodyDescription
201application/json, ReportScheduleViewCreated.
400application/problem+json, ProblemDetailsThe request body is not valid JSON.
401application/problem+json, ProblemDetailsNo signed-in identity.
402application/problem+json, ProblemDetailsThis report is not included in your plan.
403application/problem+json, ProblemDetailsThe identity does not hold the required permission.
404application/problem+json, ProblemDetailsSchedule not found.
409application/problem+json, ProblemDetailsA schedule with that name already exists.
500application/problem+json, ProblemDetailsNo client store in request context.

201 response body

FieldTypeDescription
cannedReportstring
createdAtrequiredstring (date-time)
createdByUserIdstring
cronExprrequiredstring
definitionIdstring
enabledrequiredboolean
graceSecondsrequiredinteger
lastRunAtstring (date-time) or null
missedRunPolicyrequiredstring
namerequiredstring
nextDueAtstring (date-time) or null
pausedrequiredboolean
pausedReasonstring
publicIdrequiredstring
recipientsrequiredarray of string
timezonerequiredstring
updatedAtrequiredstring (date-time)
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
curl -X POST 'https://depot.example.com/api/v1/reports/schedules' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-b 'outpost_console=<console-session>' \
--data '{
"cannedReport": "string",
"cronExpr": "string",
"definitionId": "string",
"enabled": false,
"graceSeconds": 0,
"missedRunPolicy": "string",
"name": "string",
"recipients": [
"string"
],
"timezone": "string"
}'

GET /api/v1/reports/schedules/{scheduleId}

Section titled “GET /api/v1/reports/schedules/{scheduleId}”

GETreport:readtenant facehosteditmspremoteIdempotent

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

Get report schedule

NameInTypeRequiredDescription
scheduleIdpathstringYesA uuid.
StatusBodyDescription
200application/json, ReportScheduleViewSuccess.
401application/problem+json, ProblemDetailsNo signed-in identity.
403application/problem+json, ProblemDetailsThe identity does not hold report:read.
404application/problem+json, ProblemDetailsNo resource matches that id.
500application/problem+json, ProblemDetailsNo client store in request context.

200 response body

FieldTypeDescription
cannedReportstring
createdAtrequiredstring (date-time)
createdByUserIdstring
cronExprrequiredstring
definitionIdstring
enabledrequiredboolean
graceSecondsrequiredinteger
lastRunAtstring (date-time) or null
missedRunPolicyrequiredstring
namerequiredstring
nextDueAtstring (date-time) or null
pausedrequiredboolean
pausedReasonstring
publicIdrequiredstring
recipientsrequiredarray of string
timezonerequiredstring
updatedAtrequiredstring (date-time)
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
# This operation is idempotent. Repeating it does not repeat its effect.
curl -X GET 'https://depot.example.com/api/v1/reports/schedules/<scheduleId>' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-b 'outpost_console=<console-session>'

PUT /api/v1/reports/schedules/{scheduleId}

Section titled “PUT /api/v1/reports/schedules/{scheduleId}”

PUTreport:scheduletenant facehosteditmspremoteIdempotent

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

Update report schedule

NameInTypeRequiredDescription
scheduleIdpathstringYesA uuid.

Required, sent as application/json.

FieldTypeDescription
cannedReportstring or null
cronExprstring or null
definitionIdstring or null
enabledboolean or null
graceSecondsinteger or null
missedRunPolicystring or null
namestring or null
recipientsrequiredarray of string
timezonestring or null
StatusBodyDescription
200application/json, ReportScheduleViewSuccess.
400application/problem+json, ProblemDetailsThe request body is not valid JSON.
401application/problem+json, ProblemDetailsNo signed-in identity.
403application/problem+json, ProblemDetailsThe identity does not hold report:schedule.
404application/problem+json, ProblemDetailsNo resource matches that id.
409application/problem+json, ProblemDetailsA schedule with that name already exists.
500application/problem+json, ProblemDetailsNo client store in request context.

200 response body

FieldTypeDescription
cannedReportstring
createdAtrequiredstring (date-time)
createdByUserIdstring
cronExprrequiredstring
definitionIdstring
enabledrequiredboolean
graceSecondsrequiredinteger
lastRunAtstring (date-time) or null
missedRunPolicyrequiredstring
namerequiredstring
nextDueAtstring (date-time) or null
pausedrequiredboolean
pausedReasonstring
publicIdrequiredstring
recipientsrequiredarray of string
timezonerequiredstring
updatedAtrequiredstring (date-time)
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
# This operation is idempotent. Repeating it does not repeat its effect.
curl -X PUT 'https://depot.example.com/api/v1/reports/schedules/<scheduleId>' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-b 'outpost_console=<console-session>' \
--data '{
"cannedReport": "string",
"cronExpr": "string",
"definitionId": "string",
"enabled": false,
"graceSeconds": 0,
"missedRunPolicy": "string",
"name": "string",
"recipients": [
"string"
],
"timezone": "string"
}'

DELETE /api/v1/reports/schedules/{scheduleId}

Section titled “DELETE /api/v1/reports/schedules/{scheduleId}”

DELETEreport:scheduletenant facehosteditmspremoteIdempotent

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

Delete report schedule

NameInTypeRequiredDescription
scheduleIdpathstringYesA uuid.
StatusBodyDescription
204NoneSuccess, with no body.
401application/problem+json, ProblemDetailsNo signed-in identity.
403application/problem+json, ProblemDetailsThe identity does not hold report:schedule.
404application/problem+json, ProblemDetailsNo resource matches that id.
500application/problem+json, ProblemDetailsNo client store in request context.
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
# This operation is idempotent. Repeating it does not repeat its effect.
curl -X DELETE 'https://depot.example.com/api/v1/reports/schedules/<scheduleId>' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-b 'outpost_console=<console-session>'

POST /api/v1/reports/schedules/{scheduleId}/pause

Section titled “POST /api/v1/reports/schedules/{scheduleId}/pause”

POSTreport:scheduletenant facehosteditmspremote

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

Pause report schedule

NameInTypeRequiredDescription
scheduleIdpathstringYesA uuid.
StatusBodyDescription
200application/json, ReportScheduleViewSuccess.
401application/problem+json, ProblemDetailsNo signed-in identity.
403application/problem+json, ProblemDetailsThe identity does not hold report:schedule.
404application/problem+json, ProblemDetailsNo resource matches that id.
500application/problem+json, ProblemDetailsNo client store in request context.

200 response body

FieldTypeDescription
cannedReportstring
createdAtrequiredstring (date-time)
createdByUserIdstring
cronExprrequiredstring
definitionIdstring
enabledrequiredboolean
graceSecondsrequiredinteger
lastRunAtstring (date-time) or null
missedRunPolicyrequiredstring
namerequiredstring
nextDueAtstring (date-time) or null
pausedrequiredboolean
pausedReasonstring
publicIdrequiredstring
recipientsrequiredarray of string
timezonerequiredstring
updatedAtrequiredstring (date-time)
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
curl -X POST 'https://depot.example.com/api/v1/reports/schedules/<scheduleId>/pause' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-b 'outpost_console=<console-session>'

POST /api/v1/reports/schedules/{scheduleId}/resume

Section titled “POST /api/v1/reports/schedules/{scheduleId}/resume”

POSTreport:scheduletenant facehosteditmspremote

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

resumeReportSchedule clears the pause and DOES NOT move the cursor.

A schedule paused for a week must not deliver seven reports on resume, which is what re-arming a stale cursor would do.

NameInTypeRequiredDescription
scheduleIdpathstringYesA uuid.
StatusBodyDescription
200application/json, ReportScheduleViewSuccess.
401application/problem+json, ProblemDetailsNo signed-in identity.
403application/problem+json, ProblemDetailsThe identity does not hold report:schedule.
404application/problem+json, ProblemDetailsNo resource matches that id.
500application/problem+json, ProblemDetailsNo client store in request context.

200 response body

FieldTypeDescription
cannedReportstring
createdAtrequiredstring (date-time)
createdByUserIdstring
cronExprrequiredstring
definitionIdstring
enabledrequiredboolean
graceSecondsrequiredinteger
lastRunAtstring (date-time) or null
missedRunPolicyrequiredstring
namerequiredstring
nextDueAtstring (date-time) or null
pausedrequiredboolean
pausedReasonstring
publicIdrequiredstring
recipientsrequiredarray of string
timezonerequiredstring
updatedAtrequiredstring (date-time)
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
curl -X POST 'https://depot.example.com/api/v1/reports/schedules/<scheduleId>/resume' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-b 'outpost_console=<console-session>'

POST /api/v1/reports/schedules/{scheduleId}/run-now

Section titled “POST /api/v1/reports/schedules/{scheduleId}/run-now”

POSTreport:scheduletenant facehosteditmspremoteIdempotent

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

runReportScheduleNow arms the cursor so the next sweep delivers this report.

IT DOES NOT DELIVER ANYTHING ITSELF, and that is the point: delivery is guarded by the occurrence key on the run row, which is what stops a customer receiving their compliance report twice, and a second sender inside an HTTP handler would be a second path past that guard.

A disabled or paused schedule is REFUSED rather than armed, because the sweep only claims enabled, unpaused rows: arming one would leave a button that silently does nothing, which is worse than one that says why.

NameInTypeRequiredDescription
scheduleIdpathstringYesA uuid.
StatusBodyDescription
200application/json, ReportScheduleViewSuccess.
400application/problem+json, ProblemDetailsOne or more validation errors occurred.
401application/problem+json, ProblemDetailsNo signed-in identity.
403application/problem+json, ProblemDetailsThe identity does not hold report:schedule.
404application/problem+json, ProblemDetailsNo resource matches that id.
409application/problem+json, ProblemDetailsThis schedule is turned off, so nothing would be delivered. Turn it on first.
500application/problem+json, ProblemDetailsNo client store in request context.

200 response body

FieldTypeDescription
cannedReportstring
createdAtrequiredstring (date-time)
createdByUserIdstring
cronExprrequiredstring
definitionIdstring
enabledrequiredboolean
graceSecondsrequiredinteger
lastRunAtstring (date-time) or null
missedRunPolicyrequiredstring
namerequiredstring
nextDueAtstring (date-time) or null
pausedrequiredboolean
pausedReasonstring
publicIdrequiredstring
recipientsrequiredarray of string
timezonerequiredstring
updatedAtrequiredstring (date-time)
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
# This operation is idempotent. Repeating it does not repeat its effect.
curl -X POST 'https://depot.example.com/api/v1/reports/schedules/<scheduleId>/run-now' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-b 'outpost_console=<console-session>'

GET /api/v1/reports/schedules/{scheduleId}/runs

Section titled “GET /api/v1/reports/schedules/{scheduleId}/runs”

GETreport:readtenant facehosteditmspremoteIdempotent

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

List report schedule runs

NameInTypeRequiredDescription
scheduleIdpathstringYesA uuid.
pagequeryintegerNoOne-based page number. Defaults to 1.
pageSizequeryintegerNoRows per page, 1 to 200. Defaults to 50.
StatusBodyDescription
200application/json, PagedResultReportScheduleRunViewSuccess.
400application/problem+json, ProblemDetailsOne or more validation errors occurred.
401application/problem+json, ProblemDetailsNo signed-in identity.
403application/problem+json, ProblemDetailsThe identity does not hold report:read.
404application/problem+json, ProblemDetailsNo resource matches that id.
500application/problem+json, ProblemDetailsNo client store in request context.

200 response body

FieldTypeDescription
itemsrequiredarray of ReportScheduleRunView
items[].dueAtrequiredstring (date-time)
items[].errorstring
items[].occurrenceKeyrequiredstring
items[].pdfBytesrequiredinteger

int64.

items[].ranAtrequiredstring (date-time)
items[].recipientCountrequiredinteger
items[].schedulePublicIdrequiredstring
items[].statusrequiredstring
pagerequiredinteger
pageSizerequiredinteger
totalrequiredinteger
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
# This operation is idempotent. Repeating it does not repeat its effect.
curl -X GET 'https://depot.example.com/api/v1/reports/schedules/<scheduleId>/runs?page=0&pageSize=0' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-b 'outpost_console=<console-session>'

Content is licensed CC BY 4.0. Code samples are MIT. Outpost and the Outpost mark are trademarks of Outpost Business Solutions, PBC and are not covered by either license.