---
title: "Update Meter"
method: PATCH
path: "/v1/meters/{id}"
tags: ["meters", "public"]
---

# Update Meter

`PATCH /v1/meters/{id}`

Update a meter.

**Scopes**: `meters:write`

## Path parameters

- `id` string, uuid4, required — The meter ID.

## Request body

- MeterUpdate
  - `metadata` object — Key-value object allowing you to store additional information. The key must be a string with a maximum length of **40 characters**. The value must be either: * A string with a maximum length of **500 characters** * An integer * A floating-point number * A boolean You can store up to **50 key-value pairs**.
  - `name` string, nullable — The name of the meter. Will be shown on customer's invoices and usage.
  - `unit` 'scalar' | 'token' | 'custom'
  - `custom_label` string, nullable — The label for the custom unit. Required when unit is 'custom'.
  - `custom_multiplier` integer, nullable — The multiplier to convert from base unit to display scale. Required when unit is 'custom'.
  - `filter` Filter
    - `conjunction` 'and' | 'or', required
    - `clauses` union[], required
      - union
        - FilterClause
          - `property` string, required
          - `operator` 'eq' | 'ne' | 'gt' | 'gte' | 'lt' | 'lte' | 'like' | 'not_like', required
          - `value` union, required
            - string
            - integer
            - boolean
        - Filter — recursive
  - `aggregation` union — The aggregation to apply on the filtered events to calculate the meter.
    - CountAggregation
      - `func` 'count'
    - PropertyAggregation
      - `func` 'sum' | 'max' | 'min' | 'avg', required
      - `property` string, required
    - UniqueAggregation
      - `func` 'unique'
      - `property` string, required
  - `is_archived` boolean, nullable — Whether the meter is archived. Archived meters are no longer used for billing.

## Response `200`

Meter updated.

- Meter
  - `metadata` MetadataOutputType, required
  - `created_at` string, date-time, required — Creation timestamp of the object.
  - `modified_at` string, date-time, nullable, required — Last modification timestamp of the object.
  - `id` string, uuid4, required — The ID of the object.
  - `name` string, required — The name of the meter. Will be shown on customer's invoices and usage.
  - `unit` 'scalar' | 'token' | 'custom', required
  - `custom_label` string, nullable — The label for the custom unit.
  - `custom_multiplier` integer, nullable — The multiplier to convert from base unit to display scale.
  - `filter` Filter, required
    - `conjunction` 'and' | 'or', required
    - `clauses` union[], required
      - union
        - FilterClause
          - `property` string, required
          - `operator` 'eq' | 'ne' | 'gt' | 'gte' | 'lt' | 'lte' | 'like' | 'not_like', required
          - `value` union, required
            - string
            - integer
            - boolean
        - Filter — recursive
  - `aggregation` union, required — The aggregation to apply on the filtered events to calculate the meter.
    - CountAggregation
      - `func` 'count'
    - PropertyAggregation
      - `func` 'sum' | 'max' | 'min' | 'avg', required
      - `property` string, required
    - UniqueAggregation
      - `func` 'unique'
      - `property` string, required
  - `organization_id` string, uuid4, required — The ID of the organization owning the meter.
  - `archived_at` string, date-time, nullable — Whether the meter is archived and the time it was archived.

## Other responses

- `404` — Meter not found.
- `422` — Validation Error

---

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