Get Monthly Project Slow Data Report by Endpoint
:::note[Replace [[app:key]] with a valid API key from your Project]
:::
This API returns a report for one calendar month. It has one row for each monitor, grouped by project and month, with the monitor's total counts of passes, slow calls at each response time threshold, warnings, and failures. It also gives the monitor's name and the URL it calls.
The report covers every project in the organization, even when you authenticate with the API key of a single project. Rows for monitors and projects that have since been deleted are left out. To get monthly data for one project, use Get Monthly Project Data Report, which has no slow breakdown.
Request
GET https://client.apimetrics.io/api/3/organizations/{org_id}/analytics/slow-calls-monthly
| Name | In | Required? | Description |
|---|---|---|---|
org_id | Path | Yes | The Organization ID that owns all the projects. |
start_date | Query | Yes | The month to report on, as an ISO 8601 date such as 2024-07-01. |
thresholds | Query | No | Response times in milliseconds that divide slow calls into bands. Repeat the parameter for each value, for example thresholds=700&thresholds=800. Give at least two values. The default is 700, 800, 900, 1000, and 2000. |
Accept | Header | No | Set to text/csv to receive CSV instead of JSON. |
Response
The JSON response has a meta object and a data array. The meta object holds report_type (slow_calls_monthly), version, start_date, end_date, and created_at. Each item in data is one monitor for one month. The CSV response has one column for each field below, in the same order.
| Field | Type | Description |
|---|---|---|
month | Date | The first day of the month the row covers. |
project_id | String | The name of the project that owns the monitor. |
test_id | String | The name of the monitor. |
url | String | The URL the monitor calls. |
pass_count | Integer | Calls that passed or were slow, and responded faster than the lowest threshold. |
slow<threshold>_count | Integer | One field for each threshold, such as slow700_count. Calls that passed or were slow, with a response time at or above the threshold and below the next threshold. For the highest threshold, the count has no upper limit. |
warn_count | Integer | Calls with a warning result. |
fail_count | Integer | Calls that failed. |
total | Integer | All calls for the monitor in the month. |
The slow counts are bands, not running totals. With the thresholds 700 and 800, slow700_count holds calls from 700 ms up to, but not including, 800 ms, and slow800_count holds calls of 800 ms or more. To count every call of 700 ms or more, add the two fields.
The OpenAPI schema describes the slow counts as a slow_counts object keyed by threshold. The JSON and CSV responses return each count as its own slow<threshold>_count field.
Example
A request with the thresholds 700 and 800 returns rows like this one:
{
"meta": {
"report_type": "slow_calls_monthly",
"version": 1,
"start_date": "2024-07-01",
"end_date": "2024-08-01",
"created_at": "2024-08-19T22:11:46.125494"
},
"data": [
{
"month": "2024-07-01",
"project_id": "Example Project",
"test_id": "Webhooks List",
"url": "https://api.example.com/webhooks",
"pass_count": 4411,
"slow700_count": 3,
"slow800_count": 18,
"warn_count": 0,
"fail_count": 1,
"total": 4433
}
]
}