---
title: "Create feature"
method: POST
path: "/v3/openmeter/features"
tags: ["OpenMeter Features"]
---

# Create feature

`POST /v3/openmeter/features`

**Pre-release Endpoint**
This endpoint is currently in beta and is subject to change.

Create a feature.

## Request body

- CreateFeatureRequest — Feature create request.
  - `name` string, required — Display name of the resource. Between 1 and 256 characters.
  - `description` string — Optional description of the resource. Maximum 1024 characters.
  - `labels` Labels — Labels store metadata of an entity that can be used for filtering an entity list or for searching across entity types. Keys must be of length 1-63 characters, and cannot start with "kong", "konnect", "mesh", "kic", or "_".
  - `key` string, required — A key is a unique string that is used to identify a resource.
  - `meter` object — The meter that the feature is associated with and based on which usage is calculated. If not specified, the feature is static.
    - `id` string, required — The ID of the meter to associate with this feature.
    - `filters` object — Filters to apply to the dimensions of the meter.
  - `unit_cost` union — Optional per-unit cost configuration. Use "manual" for a fixed per-unit cost, or "llm" to look up cost from the LLM cost database based on meter group-by properties.
    - object — A fixed per-unit cost amount.
      - `type` 'manual', required — The type discriminator for manual unit cost.
      - `amount` string, required — Fixed per-unit cost amount in USD.
    - object — LLM cost lookup configuration. Each dimension (provider, model, token type) can be specified as either a static value or a meter group-by property name (mutually exclusive).
      - `type` 'llm', required — The type discriminator for LLM unit cost.
      - `provider_property` string — Meter group-by property that holds the LLM provider. Use this when the meter has a group-by dimension for provider. Mutually exclusive with `provider`.
      - `provider` string — Static LLM provider value (e.g., "openai", "anthropic"). Use this when the feature tracks a single provider. Mutually exclusive with `provider_property`.
      - `model_property` string — Meter group-by property that holds the model ID. Use this when the meter has a group-by dimension for model. Mutually exclusive with `model`.
      - `model` string — Static model ID value (e.g., "gpt-4", "claude-3-5-sonnet"). Use this when the feature tracks a single model. Mutually exclusive with `model_property`.
      - `token_type_property` string — Meter group-by property that holds the token type. Use this when the meter has a group-by dimension for token type. Mutually exclusive with `token_type`.
      - `token_type` 'input' | 'output' | 'cache_read' | 'cache_write' | 'reasoning' | 'request' | 'response' — Static token type value. Use this when the feature tracks a single token type (e.g., only input tokens). `request` is an alias for `input`, `response` is an alias for `output`. Mutually exclusive with `token_type_property`.
      - `pricing` object — Resolved per-token pricing from the LLM cost database. Populated in responses when the provider and model can be determined, either from static values or from meter group-by filters with exact matches.
        - `input_per_token` string, required — Cost per input token in USD.
        - `output_per_token` string, required — Cost per output token in USD.
        - `cache_read_per_token` string — Cost per cache read token in USD.
        - `reasoning_per_token` string — Cost per reasoning token in USD.
        - `cache_write_per_token` string — Cost per cache write token in USD.

## Response `201`

Feature created response.

- Feature — A capability or billable dimension offered by a provider.
  - `id` string, required — ULID (Universally Unique Lexicographically Sortable Identifier).
  - `name` string, required — Display name of the resource. Between 1 and 256 characters.
  - `description` string — Optional description of the resource. Maximum 1024 characters.
  - `labels` Labels — Labels store metadata of an entity that can be used for filtering an entity list or for searching across entity types. Keys must be of length 1-63 characters, and cannot start with "kong", "konnect", "mesh", "kic", or "_".
  - `created_at` string, date-time, required — An ISO-8601 timestamp representation of entity creation date.
  - `updated_at` string, date-time, required — An ISO-8601 timestamp representation of entity last update date.
  - `deleted_at` string, date-time — An ISO-8601 timestamp representation of entity deletion date.
  - `key` string, required — A key is a unique string that is used to identify a resource.
  - `meter` object — The meter that the feature is associated with and based on which usage is calculated. If not specified, the feature is static.
    - `id` string, required — The ID of the meter to associate with this feature.
    - `filters` object — Filters to apply to the dimensions of the meter.
  - `unit_cost` union — Optional per-unit cost configuration. Use "manual" for a fixed per-unit cost, or "llm" to look up cost from the LLM cost database based on meter group-by properties.
    - object — A fixed per-unit cost amount.
      - `type` 'manual', required — The type discriminator for manual unit cost.
      - `amount` string, required — Fixed per-unit cost amount in USD.
    - object — LLM cost lookup configuration. Each dimension (provider, model, token type) can be specified as either a static value or a meter group-by property name (mutually exclusive).
      - `type` 'llm', required — The type discriminator for LLM unit cost.
      - `provider_property` string — Meter group-by property that holds the LLM provider. Use this when the meter has a group-by dimension for provider. Mutually exclusive with `provider`.
      - `provider` string — Static LLM provider value (e.g., "openai", "anthropic"). Use this when the feature tracks a single provider. Mutually exclusive with `provider_property`.
      - `model_property` string — Meter group-by property that holds the model ID. Use this when the meter has a group-by dimension for model. Mutually exclusive with `model`.
      - `model` string — Static model ID value (e.g., "gpt-4", "claude-3-5-sonnet"). Use this when the feature tracks a single model. Mutually exclusive with `model_property`.
      - `token_type_property` string — Meter group-by property that holds the token type. Use this when the meter has a group-by dimension for token type. Mutually exclusive with `token_type`.
      - `token_type` 'input' | 'output' | 'cache_read' | 'cache_write' | 'reasoning' | 'request' | 'response' — Static token type value. Use this when the feature tracks a single token type (e.g., only input tokens). `request` is an alias for `input`, `response` is an alias for `output`. Mutually exclusive with `token_type_property`.
      - `pricing` object — Resolved per-token pricing from the LLM cost database. Populated in responses when the provider and model can be determined, either from static values or from meter group-by filters with exact matches.
        - `input_per_token` string, required — Cost per input token in USD.
        - `output_per_token` string, required — Cost per output token in USD.
        - `cache_read_per_token` string — Cost per cache read token in USD.
        - `reasoning_per_token` string — Cost per reasoning token in USD.
        - `cache_write_per_token` string — Cost per cache write token in USD.

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `403` — Forbidden

---

[API](https://skmtc.net/kong/apis/konnect-api-go-sdk.md) · [All operations](https://skmtc.net/kong/apis/konnect-api-go-sdk/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/kong/konnect-api-go-sdk/versions/0261aef4b1e2/schema)
