/api/v1
. When you need to query monitoring data, you can request data through query APIs. To submit data, you can use the remote write protocol or Pushgateway.API | Description | Authentication Required | Method |
/api/v1/query | Query | Yes | GET/POST |
/api/v1/query_range | Range query | Yes | GET/POST |
/api/v1/series | Series query | Yes | GET/POST |
/api/v1/labels | Labels query | Yes | GET/POST |
/api/v1/label/<label_name>/values | Label value query | Yes | GET |
/api/v1/prom/write | Data submission through remote write | Yes | remote write |
Pushgateway | Data submission through Pushgateway | Yes | SDK |
APPID
, and the password is the bearer token (generated when the instance is generated), which can be queried in the console. For more information on basic auth, please see Basic Authentication. 2xx
.Status Code | Description |
401 | Authentication failed |
400 | A parameter was missing or incorrect |
422 | An invalid expression couldn't be specified (RFC4918) |
503 | The query was unavailable or canceled |
{"status": "success" | "error","data": <data>,// When the `status` is `error`, the following data will be returned"errorType": "<string>","error": "<string>",// When there is a warning message during request execution, this field will be filled and returned"warnings": ["<string>"]}
Was this page helpful?