EP. Get Metric Latest Value
Fetch the latest value of a specific metric.
URI
/api/v1/locations/{LOCATION_ID}/metrics/{METRIC_ID}/count
Request Query Parameters
Request Parameter | Description |
---|---|
LOCATION_ID | UUID assigned to a specific location |
METRIC_ID | ID of a target metric |
Response
{
"type": "object",
"properties": {
"metric_uuid": {
"type": "string"
},
"count": {
"type": "number"
},
"float_value": {
"type": "number"
},
"formatted_value": {
"type": "string"
},
"time": {
"type": "string"
}
}
}
Response Parameter | Description |
---|---|
metric_uuid | A unique identifier of a metric. |
count | Value of a metric as integer . |
float_value | Value of a metric as float . |
formatted_value | Formatted value of a metric as string . |
time | Time when the value of this metric was acquired / derived, RFC3339 date string. Time value does not have a timezone, it is a time in location timezone. |
Sample Response
{
"data": {
"metric_uuid": "51f5c88a-d55c-46cb-8449-c197e5438f96",
"count": 64,
"float_value": 64,
"formatted_value": "64",
"time": "2024-01-28T20:19:55Z",
},
"success": true
}