Skip to content

Reports

The Prism API (port 9003) manages recurring report requests, while the worker executes schedules and delivery — decide when a report is generated and delivered, and the log of what was sent. All endpoints authenticate with the standard gck_* / prism_* key (Authentication) and are scoped to the caller.

A schedule is a report cadence (weekly, daily, or monthly) with a set of sections.

MethodPathPurpose
GET/v1/reports/schedulesList the caller’s schedules
POST/v1/reports/schedulesCreate a schedule
POST/v1/reports/schedules/defaultsCreate the default set of schedules (weekly)
PATCH/v1/reports/schedules/:idUpdate a schedule
DELETE/v1/reports/schedules/:idDelete a schedule
POST/v1/reports/schedules/:id/runRun a schedule immediately (out of cadence)

Create / update body (fields, all optional on update):

  • frequency"weekly", "daily", or "monthly".
  • sections — which report sections to include (see section defaults below).
MethodPathPurpose
GET/v1/reports/section-defaults?frequency=weeklyThe default section list for a given frequency

Returns { "sections": [...] } — the section keys enabled by default for that cadence. Use it to seed the sections field when creating a schedule.

Every time a schedule fires (or is run on demand), it records a delivery.

MethodPathPurpose
GET/v1/reports/deliveriesList recent deliveries for the caller
GET/v1/reports/deliveries/:idFetch a single delivery