Skip to main content
PUT
Error

Autorizações

Authorization
string
header
obrigatório

A staff session token, uk_st_…. Minted by sign-up, sign-in or the two-factor exchange. Only a 401 means it is spent; not_a_member (403) is about the organization named in X-Organization-Id and leaves the token good for the others.

Cabeçalhos

X-Organization-Id
string

The organization the caller is acting on — the org_… code that appears in the panel URL. It identifies; the membership JOIN is what authorizes, so a forged code reads nothing: the answer is not_a_member (403), which does not mean the session is over. Absent, the session's default organization answers, or — if that membership was revoked while the session was open — any other one the caller still holds.

Parâmetros de caminho

planId
string<uuid>
obrigatório

The plan.

featureId
string<uuid>
obrigatório

The feature it carries.

Parâmetros de consulta

environment
enum<string>
padrão:live

Which environment to act in. A view parameter, valid only on the staff surface — a machine credential never chooses its environment, it is resolved from the key.

Opções disponíveis:
live,
test

Corpo

application/json
limit
integer<int64> | null

The ceiling, on a metered feature. -1 is unlimited. Omit on the other kinds.

included_quantity
integer<int64> | null

How many units the plan grants per period, on a credit feature. Omit on the other kinds.

rollover
enum<string> | null

What happens to a credit feature's unspent units when the next grant arrives: they expire, accumulate without bound, or accumulate up to rollover_cap. Required on a credit feature; omit on the other kinds.

Opções disponíveis:
none,
all,
capped,
null
rollover_cap
integer<int64> | null

The ceiling unspent credits accumulate to, in the feature's own units. Required — and positive — exactly when rollover is capped; omit otherwise.

overdraft_limit
integer<int64> | null

How far below zero a credit feature's balance may go before a spend is refused, in the feature's own units. 0 — the balance may not go below zero — is a real value and must be said. Required on a credit feature; omit on the other kinds.

overage_meter_ref
string

The gateway's own name for the meter that prices consumption past the floor — a Stripe billing meter's event name, for instance, taken from your own gateway dashboard. Optional on a credit feature and refused on the other kinds. Omitted, the excess is not priced, which means it is refused: this is the one credit term whose absence has a safe answer, so it is the one that is not required.

Resposta

The cell.

One cell of the plan/feature matrix: how much of a feature a plan carries. A feature a plan does not carry is simply absent from the list.

feature_id
string<uuid>
feature_key
string
kind
enum<string>

The feature's kind, which decides which of the two numbers below applies.

Opções disponíveis:
boolean,
metered,
credit
limit
integer<int64> | null

The ceiling, on a metered feature; null on the other kinds. -1 is unlimited and 0 is a real limit — none at all.

unlimited
boolean

Whether limit is the unlimited sentinel, so a client never has to know the number.

included_quantity
integer<int64> | null

How many credits the plan grants per period — or per purchase, when the plan is sold at a one_time price — on a credit feature; null otherwise.

rollover
enum<string> | null

What happens to unspent credits when the next grant arrives, on a credit feature; null on the kinds that have no balance — never none, which would read as a policy somebody chose.

Opções disponíveis:
none,
all,
capped,
null
rollover_cap
integer<int64> | null

The ceiling unspent credits accumulate to, when rollover is capped; null otherwise.

overdraft_limit
integer<int64> | null

How far below zero the balance may go before a spend is refused, on a credit feature; 0 means it may not. null on the other kinds.

overage_meter_ref
string | null

Where consumption past the floor is priced at the gateway. null where nothing is — and then the spend is refused instead of billed, whatever the environment's credit_overage says.