Create a price
A price with no
metricId must use a flat-fee cadence. A usage-based price needs a metric.
Responds 201 Created.
List prices
{ "data": [ … ] }.
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Charge for a metric or a flat fee, using one of the pricing models
POST /v1/prices
{
"name": "api_call_price",
"description": "Per API call",
"metricId": "01JX0F8K4W3Z9YQ6V7M2T5R8B1",
"config": {
"model": "unit",
"unitPrice": 0.001,
"currency": "USD"
},
"cadence": "monthly",
"timing": "in_arrears"
}
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | The price’s name. Plans refer to it. |
config | object | Yes | The pricing model and its settings. See Pricing models. |
description | string | No | What the price is for. |
metricId | string | No | The metric to charge for. Leave it empty for a flat fee. |
cadence | string | No | monthly (default), quarterly, annual, one_time, or usage_based. |
timing | string | No | in_arrears (default) charges at the end of the period. in_advance charges at the start. |
metricId must use a flat-fee cadence. A usage-based price needs a metric.
Responds 201 Created.
GET /v1/prices
{ "data": [ … ] }.
PATCH /v1/prices/:id
DELETE /v1/prices/:id