Create metric report

Submit a metric report for a subgroup on a given date. Provide the recorded values as the metric tree from /api/reporting/metrics with a value set on each counted metric. Set published to true to publish the report immediately (requires full metrics write access); otherwise it is saved as a draft. The subgroup must exist or the request fails with a 404. Creating or editing a draft requires Limited Write Metrics; publishing a report, or editing one that is already published, additionally requires Full Write Metrics.

Required permission: Limited Write Metrics

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params

The metric report details

date
required

The date the report covers.

subgroup
object | null
required

The subgroup the report was submitted for. Provide the id when saving.

string | null

Notes entered on the report (max 4000 characters).

boolean | null

Whether the report has been published. Set true to publish (requires full metrics write access), false to revert to a draft, or omit to leave unchanged.

values
array of objects | null

The full metric tree with each metric's recorded value merged in. When saving, set a value on each counted metric, with sub-metrics nested under children.

values
Headers
string
enum
Defaults to application/json

Generated from available response content types

Allowed:
Responses

401

Authentication is required, or the Ocs-Api-Key header is missing or invalid.

Language
Credentials
Header
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
text/plain
application/json
text/json