---
title: "List a label's values"
description: "The values of one label among the series the selectors match (every series without match[]) between start and end (default: the last 6 hours). A UTF-8 name may be sent escaped as Prometheus 3 does (U__…). Prometheus HTTP API compatible: a Grafana Prometheus datasource's URL is the API host plus /v1/organizations/{orgId}/projects/{projectId}/obs/prometheus. Errors use Prometheus's error body (PrometheusError), with the platform's code. 422 is a query over one of its budgets (query_too_expensive, naming the budget) or one that can't be evaluated (query_failed); 429 is the organization's concurrent metric queries, or this service's capacity, with Retry-After. Reads every active dataset of the project the caller may query (obs.metrics.query); a selector's environment matcher narrows them."
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.ezghcloud.com/llms.txt
> Use this file to discover all available pages before exploring further.

Path: Observability API

`GET /v1/organizations/{orgId}/projects/{projectId}/obs/prometheus/api/v1/label/{name}/values`

The values of one label among the series the selectors match (every series without match[]) between start and end (default: the last 6 hours). A UTF-8 name may be sent escaped as Prometheus 3 does (U__…). Prometheus HTTP API compatible: a Grafana Prometheus datasource's URL is the API host plus /v1/organizations/{orgId}/projects/{projectId}/obs/prometheus. Errors use Prometheus's error body (PrometheusError), with the platform's code. 422 is a query over one of its budgets (query_too_expensive, naming the budget) or one that can't be evaluated (query_failed); 429 is the organization's concurrent metric queries, or this service's capacity, with Retry-After. Reads every active dataset of the project the caller may query (obs.metrics.query); a selector's environment matcher narrows them.

## Authentication

Requires one of the following:

- `apiKey`, http, header `Authorization`
- `oauth`, http, header `Authorization`
- `sessionCookie`, apiKey, in cookie

## Path parameters

- `ListMetricLabelValues.path.orgId` (string, required)
  - format `uuid`
- `ListMetricLabelValues.path.projectId` (string, required)
  - format `uuid`
- `ListMetricLabelValues.path.name` (string, required) — The label name.

## Query parameters

- `ListMetricLabelValues.query.match[]` (array<string>, optional) — A series selector. Repeat for several (at most 20).
- `ListMetricLabelValues.query.start` (string, optional) — Start. A Unix timestamp in seconds (a float) or an RFC 3339 time.
- `ListMetricLabelValues.query.end` (string, optional) — End. A Unix timestamp in seconds (a float) or an RFC 3339 time.
- `ListMetricLabelValues.query.limit` (integer, optional) — The most entries to return; more are truncated with a warning. 0 is the service's maximum.
  - min 0

## Code samples

### cURL

```curl
curl --request GET \
  --url https://obs.ezghcloud.com/v1/organizations/497f6eca-6276-4993-bfeb-53cbbbba6f08/projects/497f6eca-6276-4993-bfeb-53cbbbba6f08/obs/prometheus/api/v1/label/string/values \
  --header 'Authorization: Bearer <token>'
```

### TypeScript

```typescript
const url = 'https://obs.ezghcloud.com/v1/organizations/497f6eca-6276-4993-bfeb-53cbbbba6f08/projects/497f6eca-6276-4993-bfeb-53cbbbba6f08/obs/prometheus/api/v1/label/string/values';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://obs.ezghcloud.com/v1/organizations/497f6eca-6276-4993-bfeb-53cbbbba6f08/projects/497f6eca-6276-4993-bfeb-53cbbbba6f08/obs/prometheus/api/v1/label/string/values"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
```

## Responses

### 200

Label values, sorted.

#### Example

```json
{
  "data": [
    "string"
  ],
  "infos": [
    "string"
  ],
  "status": "success",
  "warnings": [
    "string"
  ]
}
```

- `ListMetricLabelValues.response.200.data` (array<string>, required)
- `ListMetricLabelValues.response.200.status` (unknown, required)
- `ListMetricLabelValues.response.200.infos` (array<string>, optional)
- `ListMetricLabelValues.response.200.warnings` (array<string>, optional)

### 400

bad_data (invalid_request): a parameter, the query's syntax or the request body isn't valid.

#### Example

```json
{
  "budget": "string",
  "code": "string",
  "error": "string",
  "errorType": "string",
  "status": "error"
}
```

- `ListMetricLabelValues.response.400.code` (string, required) — The platform's error code, as in every other EZGH Cloud API.
  - maxLength 64; pattern `^[a-z][a-z0-9_]*$`
- `ListMetricLabelValues.response.400.error` (string, required) — What went wrong, for people.
- `ListMetricLabelValues.response.400.errorType` (string, required) — bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.
- `ListMetricLabelValues.response.400.status` (unknown, required)
- `ListMetricLabelValues.response.400.budget` (string, optional) — query_too_expensive: the budget the query ran over.

### 401

unauthorized (unauthenticated): no credential, or one that doesn't check out.

#### Example

```json
{
  "budget": "string",
  "code": "string",
  "error": "string",
  "errorType": "string",
  "status": "error"
}
```

- `ListMetricLabelValues.response.401.code` (string, required) — The platform's error code, as in every other EZGH Cloud API.
  - maxLength 64; pattern `^[a-z][a-z0-9_]*$`
- `ListMetricLabelValues.response.401.error` (string, required) — What went wrong, for people.
- `ListMetricLabelValues.response.401.errorType` (string, required) — bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.
- `ListMetricLabelValues.response.401.status` (unknown, required)
- `ListMetricLabelValues.response.401.budget` (string, optional) — query_too_expensive: the budget the query ran over.

### 403

forbidden (access_denied, forbidden_origin): the caller's policies don't allow the action, or a cookie-authenticated POST came from an origin that isn't allowed.

#### Example

```json
{
  "budget": "string",
  "code": "string",
  "error": "string",
  "errorType": "string",
  "status": "error"
}
```

- `ListMetricLabelValues.response.403.code` (string, required) — The platform's error code, as in every other EZGH Cloud API.
  - maxLength 64; pattern `^[a-z][a-z0-9_]*$`
- `ListMetricLabelValues.response.403.error` (string, required) — What went wrong, for people.
- `ListMetricLabelValues.response.403.errorType` (string, required) — bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.
- `ListMetricLabelValues.response.403.status` (unknown, required)
- `ListMetricLabelValues.response.403.budget` (string, optional) — query_too_expensive: the budget the query ran over.

### 404

not_found (not_found): unknown, malformed, or in an organization the caller isn't in.

#### Example

```json
{
  "budget": "string",
  "code": "string",
  "error": "string",
  "errorType": "string",
  "status": "error"
}
```

- `ListMetricLabelValues.response.404.code` (string, required) — The platform's error code, as in every other EZGH Cloud API.
  - maxLength 64; pattern `^[a-z][a-z0-9_]*$`
- `ListMetricLabelValues.response.404.error` (string, required) — What went wrong, for people.
- `ListMetricLabelValues.response.404.errorType` (string, required) — bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.
- `ListMetricLabelValues.response.404.status` (unknown, required)
- `ListMetricLabelValues.response.404.budget` (string, optional) — query_too_expensive: the budget the query ran over.

### 422

execution or timeout (query_too_expensive, with budget; query_failed): the query couldn't be evaluated within its limits.

#### Example

```json
{
  "budget": "string",
  "code": "string",
  "error": "string",
  "errorType": "string",
  "status": "error"
}
```

- `ListMetricLabelValues.response.422.code` (string, required) — The platform's error code, as in every other EZGH Cloud API.
  - maxLength 64; pattern `^[a-z][a-z0-9_]*$`
- `ListMetricLabelValues.response.422.error` (string, required) — What went wrong, for people.
- `ListMetricLabelValues.response.422.errorType` (string, required) — bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.
- `ListMetricLabelValues.response.422.status` (unknown, required)
- `ListMetricLabelValues.response.422.budget` (string, optional) — query_too_expensive: the budget the query ran over.

### 429

unavailable (too_many_requests), with Retry-After.

#### Example

```json
{
  "budget": "string",
  "code": "string",
  "error": "string",
  "errorType": "string",
  "status": "error"
}
```

- `ListMetricLabelValues.response.429.code` (string, required) — The platform's error code, as in every other EZGH Cloud API.
  - maxLength 64; pattern `^[a-z][a-z0-9_]*$`
- `ListMetricLabelValues.response.429.error` (string, required) — What went wrong, for people.
- `ListMetricLabelValues.response.429.errorType` (string, required) — bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.
- `ListMetricLabelValues.response.429.status` (unknown, required)
- `ListMetricLabelValues.response.429.budget` (string, optional) — query_too_expensive: the budget the query ran over.

### 500

internal (internal_error): a bug; the details are in the logs, under the request ID.

#### Example

```json
{
  "budget": "string",
  "code": "string",
  "error": "string",
  "errorType": "string",
  "status": "error"
}
```

- `ListMetricLabelValues.response.500.code` (string, required) — The platform's error code, as in every other EZGH Cloud API.
  - maxLength 64; pattern `^[a-z][a-z0-9_]*$`
- `ListMetricLabelValues.response.500.error` (string, required) — What went wrong, for people.
- `ListMetricLabelValues.response.500.errorType` (string, required) — bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.
- `ListMetricLabelValues.response.500.status` (unknown, required)
- `ListMetricLabelValues.response.500.budget` (string, optional) — query_too_expensive: the budget the query ran over.

### 503

unavailable (unavailable): a dependency the request needs is down. Retry after Retry-After.

#### Example

```json
{
  "budget": "string",
  "code": "string",
  "error": "string",
  "errorType": "string",
  "status": "error"
}
```

- `ListMetricLabelValues.response.503.code` (string, required) — The platform's error code, as in every other EZGH Cloud API.
  - maxLength 64; pattern `^[a-z][a-z0-9_]*$`
- `ListMetricLabelValues.response.503.error` (string, required) — What went wrong, for people.
- `ListMetricLabelValues.response.503.errorType` (string, required) — bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.
- `ListMetricLabelValues.response.503.status` (unknown, required)
- `ListMetricLabelValues.response.503.budget` (string, optional) — query_too_expensive: the budget the query ran over.


Source: https://docs.ezghcloud.com/obs-api/ListMetricLabelValues/index.md
