Statistics Service
Statistics service allows retrieving aggregated usage statistics for a project or tenant.
All endpoints require an authorization header with a valid token with at least admin scope for the project at hand. See Authorization
Endpoints
Get project statistics for a time interval
Request for statistics
POST /rest/statistics/tenants/{tenant}/projects/{project}?unit=month&startDate=2023-05-01T00:00:00.000Z&endDate=2023-06-01T00:00:00.000Z
Host: api.priintcloud.com
Authorization: Bearer {access_token}
Accept: application/json
| Path Parameter | Description |
|---|---|
| tenant | Tenant name, e.g. "example.com" |
| project | Project name, e.g. "my-first-datasheet" |
| Query-Parameter | Required | Default | Description |
|---|---|---|---|
| unit | no | Any of 'hour', 'day', 'month', or 'year' | |
| startDate | no | List entries at or after the given ISO dateTime | |
| endDate | no | List entries before the given ISO dateTime |
The response is a list of 0-to-n entries each holding aggregated information on one piece of unit within the selected interval. Start date and end date defined the outer borders of the interval.
Response for statistics request (success)
200 OK
Content-Type: application/json
[
{
"tenant": "example.com",
"project": "my-first-datasheet",
"unit": "month", // type of interval
"startDate": "2023-05-01T00:00:00Z", // interval start (incl).
"endDate": "2023-06-01T00:00:00Z", // interval end (excl).
"tickets": 77, // number of jobs executed during the interval
"errors": 40, // number of errors registered during the interval
"processingMsec": 59342, // cumulated pure rendering time in msec
"processingPages": 0, // cumulated number of pages created for the tickets
"redeliveries": 9, // number of re-deliveries, when a job failed on first attempt
"totalMsec": 4323115, // cumulated total round-trip time from start to completion in msec
"downloadRequests": 77, // cumulated number of media assets downloaded
"downloadBytes": 8862, // cumulated number of bytes of all downloaded media assets
"downloadMsec": 0, // cumulated msecs for all media asset downloads (excl. cache hits) (downloads may be parallel)
"uploadRequests": 0, // cumulated number of asset uploads (PDF)
"uploadBytes": 0, // cumulated number of bytes of all asset uploads (PDF)
"uploadMsec": 0, // cumulated msecs for all asset uploads (PDF)
"cacheHits": 0 // number of hits in media asset cache
}
]