Get historical stats for a single service
GET {{fastly_url}}/stats/service/{{service_id}}?by&from®ion&to
Fetches historical stats for a given service.
Authorization: Requires API token.
Request Params
Key | Datatype | Required | Description |
---|---|---|---|
by | null | Duration of sample windows. One of: |
hour - Group data by hour.
minute - Group data by minute.
day - Group data by day. |
| from
| null | | Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the Chronic Ruby library, such as 'yesterday', or 'two weeks ago'. Default varies based on the value of by. |
| region
| null | | Limit query to a specific geographic region. One of:
usa - North America.
europe - Europe.
anzac - Australia and New Zealand.
asia - Asia.
asia_india - India.
asia_southkorea - South Korea.
africa_std - Africa.
southamerica_std - South America. |
| to
| null | | Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as from. |
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Host | string | ||
Accept | string |