Skip to content

List label names (form POST)

The label names of the series the selectors match (every series without match[]) between start and end (default: the last 6 hours). 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. Not idempotent and nothing is kept: the form body carries the same parameters as the GET's query string.

POST
https://obs.ezghcloud.com/v1/organizations/{orgId}/projects/{projectId}/obs/prometheus/api/v1/labels

Authorization

  • apiKeyoptionalHTTP
  • oauthoptionalHTTP
  • sessionCookieoptionalAPI key in cookie

Path parameters

  • orgIdstringrequired
    format: uuid
  • projectIdstringrequired
    format: uuid

Request bodyX-WWW-FORM-URLENCODEDoptional

  • endoptionalstring

    End. A Unix timestamp in seconds (a float) or an RFC 3339 time.

  • limitoptionalinteger

    The most entries to return; more are truncated with a warning. 0 is the service's maximum.

    minimum: 0
  • match[]optionalarray ofstring

    A series selector. Repeat for several (at most 20).

  • startoptionalstring

    Start. A Unix timestamp in seconds (a float) or an RFC 3339 time.

Returns

200

Label names, sorted.

JSON
  • dataarray ofstringrequired
  • statusunknownrequired
  • infosoptionalarray ofstring
  • warningsoptionalarray ofstring

400

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

JSON
  • codestringrequired

    The platform's error code, as in every other EZGH Cloud API.

    maxLength: 64, pattern: ^[a-z][a-z0-9_]*$
  • errorstringrequired

    What went wrong, for people.

  • errorTypestringrequired

    bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.

  • statusunknownrequired
  • budgetoptionalstring

    query_too_expensive: the budget the query ran over.

401

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

JSON
  • codestringrequired

    The platform's error code, as in every other EZGH Cloud API.

    maxLength: 64, pattern: ^[a-z][a-z0-9_]*$
  • errorstringrequired

    What went wrong, for people.

  • errorTypestringrequired

    bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.

  • statusunknownrequired
  • budgetoptionalstring

    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.

JSON
  • codestringrequired

    The platform's error code, as in every other EZGH Cloud API.

    maxLength: 64, pattern: ^[a-z][a-z0-9_]*$
  • errorstringrequired

    What went wrong, for people.

  • errorTypestringrequired

    bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.

  • statusunknownrequired
  • budgetoptionalstring

    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.

JSON
  • codestringrequired

    The platform's error code, as in every other EZGH Cloud API.

    maxLength: 64, pattern: ^[a-z][a-z0-9_]*$
  • errorstringrequired

    What went wrong, for people.

  • errorTypestringrequired

    bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.

  • statusunknownrequired
  • budgetoptionalstring

    query_too_expensive: the budget the query ran over.

413

bad_data (payload_too_large): the form body is over the endpoint's limit.

JSON
  • codestringrequired

    The platform's error code, as in every other EZGH Cloud API.

    maxLength: 64, pattern: ^[a-z][a-z0-9_]*$
  • errorstringrequired

    What went wrong, for people.

  • errorTypestringrequired

    bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.

  • statusunknownrequired
  • budgetoptionalstring

    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.

JSON
  • codestringrequired

    The platform's error code, as in every other EZGH Cloud API.

    maxLength: 64, pattern: ^[a-z][a-z0-9_]*$
  • errorstringrequired

    What went wrong, for people.

  • errorTypestringrequired

    bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.

  • statusunknownrequired
  • budgetoptionalstring

    query_too_expensive: the budget the query ran over.

429

unavailable (too_many_requests), with Retry-After.

JSON
  • codestringrequired

    The platform's error code, as in every other EZGH Cloud API.

    maxLength: 64, pattern: ^[a-z][a-z0-9_]*$
  • errorstringrequired

    What went wrong, for people.

  • errorTypestringrequired

    bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.

  • statusunknownrequired
  • budgetoptionalstring

    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.

JSON
  • codestringrequired

    The platform's error code, as in every other EZGH Cloud API.

    maxLength: 64, pattern: ^[a-z][a-z0-9_]*$
  • errorstringrequired

    What went wrong, for people.

  • errorTypestringrequired

    bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.

  • statusunknownrequired
  • budgetoptionalstring

    query_too_expensive: the budget the query ran over.

503

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

JSON
  • codestringrequired

    The platform's error code, as in every other EZGH Cloud API.

    maxLength: 64, pattern: ^[a-z][a-z0-9_]*$
  • errorstringrequired

    What went wrong, for people.

  • errorTypestringrequired

    bad_data, unauthorized, forbidden, not_found, execution, timeout, unavailable or internal. Treat it as an open string.

  • statusunknownrequired
  • budgetoptionalstring

    query_too_expensive: the budget the query ran over.

Navigation

Type to search…

↑↓ navigate↵ selectEsc close