listMetrics method
Written by
Updated at August 11, 2025
Returns a list of metrics.
HTTP request
GET https://monitoring.api.cloud.yandex.net/monitoring/v2/metrics
Query parameters
| Parameter | Description |
|---|---|
| folderId | This is a required field. Metric folder ID. The maximum string length is 50 characters. |
| selectors | Label selectors for metrics. |
| fromTime | Optional parameter for selecting metrics from a specified time interval. It specifies the time interval start point in RFC3339 format. |
| toTime | Optional parameter for selecting metrics from a specified time interval. It specifies the time interval endpoint in RFC3339 format. |
The fromTime and toTime parameters are only used together. The response returns metrics that have data in the specified interval. To keep the index for such queries concise and efficient, the system:
- Ensures each response contains metric data for the period between the metric’s creation and its last record, even if there are gaps in the data.
- Updates the index every four to six hours for existing metrics. Adds new metrics immediately.
Response
HTTP Code: 200 - OK
{
"metrics": [
{
"name": "string",
"labels": "object",
"type": "string"
}
]
}
| Field | Description |
|---|---|
| metrics[] | object List of metrics. |
| metrics[]. name |
string Metric name. |
| metrics[]. labels |
object Metric labels in |
| metrics[]. type |
string Metric type.
|