---
title: "Get meter"
method: GET
path: "/api/v1/meters/{meterIdOrSlug}"
tags: ["Meters"]
---

# Get meter

`GET /api/v1/meters/{meterIdOrSlug}`

Get a meter by ID or slug.

## Path parameters

- `meterIdOrSlug` string, required

## Response `200`

The request has succeeded.

- Meter — A meter is a configuration that defines how to match and aggregate events.
  - `id` string, required — A unique identifier for the resource.
  - `description` string — Optional description of the resource. Maximum 1024 characters.
  - `metadata` Metadata — Set of key-value pairs. Metadata can be used to store additional information about a resource.
  - `createdAt` string, date-time, required — Timestamp of when the resource was created.
  - `updatedAt` string, date-time, required — Timestamp of when the resource was last updated.
  - `deletedAt` string, date-time — Timestamp of when the resource was permanently deleted.
  - `name` string — Human-readable name for the resource. Between 1 and 256 characters. Defaults to the slug if not specified.
  - `slug` string, required — A unique, human-readable identifier for the meter. Must consist only alphanumeric and underscore characters.
  - `aggregation` 'SUM' | 'COUNT' | 'UNIQUE_COUNT' | 'AVG' | 'MIN' | 'MAX' | 'LATEST', required — The aggregation type to use for the meter.
  - `eventType` string, required — The event type to aggregate.
  - `eventFrom` string, date-time — The date since the meter should include events. Useful to skip old events. If not specified, all historical events are included.
  - `valueProperty` string — JSONPath expression to extract the value from the ingested event's data property. The ingested value for SUM, AVG, MIN, and MAX aggregations is a number or a string that can be parsed to a number. For UNIQUE_COUNT aggregation, the ingested value must be a string. For COUNT aggregation the valueProperty is ignored.
  - `groupBy` object — Named JSONPath expressions to extract the group by values from the event data. Keys must be unique and consist only alphanumeric and underscore characters.
  - `annotations` Annotations — Set of key-value pairs managed by the system. Cannot be modified by user.

## Other responses

- `400` — The server cannot or will not process the request due to something that is perceived to be a client error (e.g., malformed request syntax, invalid request message framing, or deceptive request routing).
- `401` — The request has not been applied because it lacks valid authentication credentials for the target resource.
- `403` — The server understood the request but refuses to authorize it.
- `404` — The origin server did not find a current representation for the target resource or is not willing to disclose that one exists.
- `412` — One or more conditions given in the request header fields evaluated to false when tested on the server.
- `500` — The server encountered an unexpected condition that prevented it from fulfilling the request.
- `503` — The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.
- `default` — An unexpected error response.

---

[API](https://skmtc.net/openmeterio/apis/openmeter-api.md) · [All operations](https://skmtc.net/openmeterio/apis/openmeter-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/openmeterio/openmeter-api/revisions/1cd97f063f4a/schema)
