Skip to main content

Get metric data

GET

Returns a list of datapoints and corridors for a single metric over a requested time range.

Data availability

Metric datapoints and corridors from this endpoint are available only after Eyer has collected enough data to start building baselines. In most cases, this happens within 7 days after ingestion begins.

Path parameters

  • node-id: required integer path parameter
  • metric-id: required string path parameter

Query parameters

  • from: optional ISO 8601 datetime; lower bound of the requested time range. If from and to are not provided, the API defaults to the last 15 minutes
  • to: optional ISO 8601 datetime; upper bound of the requested time range. The time window between from and to cannot exceed 48 hours
  • aggregation: optional string; supported values: avg, max, sum

Response

  • 200 OK

The response is a Metric data response object.

When corridor data is available, each corridor band is returned with up and down values. sup and inf can be null when those bands are not present.

{
"node": 10,
"metric": "2b953ac0-f047-45e0-a8e4-bc66e0593eff",
"aggregation": "avg",
"data": [
{
"timestamp": 1763035200000,
"smoothened": 42.1,
"corridors": {
"main": {
"up": 45.3,
"down": 39.4
},
"sup": {
"up": 47.8,
"down": 37.1
},
"inf": {
"up": 43.6,
"down": 40.8
}
}
}
]
}

Errors

  • 400: invalid or missing parameters
  • 401: unauthorized
  • 403: forbidden