Archive a price
Requires billing:write. Withdraws an offer without replacing it — the plan stops being sellable in that currency and recurrence.
The only edit a price accepts, and idempotent: the act is “this is no longer sold”, and doing it twice does not move the date it stopped being sold. Existing subscriptions keep the price, which is the whole reason it is archived rather than deleted.
To change the money instead, use /reprice — it does this and creates the replacement in one transaction.
Autorizações
A staff session token, uk_st_…. Minted by sign-up, sign-in or the two-factor exchange.
Cabeçalhos
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. Absent, the session's default organization answers.
Parâmetros de caminho
The price to withdraw.
Parâmetros de consulta
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.
live, test Resposta
The price, now archived.
One plan's amount in one currency. A plan has many prices, one per currency: selling in BRL and USD is a price per currency, a number you chose, never a conversion at display time.
A price is immutable. Repricing means creating a new price and archiving the old one, because a subscription refers to the price it was sold at and editing the amount would silently change what somebody agreed to pay.
one_time is a lifetime deal or a one-off purchase and carries no interval; recurring always carries one.
recurring, one_time ISO 4217, uppercase. Never absent — an amount with no currency is not a price.
"BRL"
The amount as an integer in the currency's minor unit. 14900 is R$149.00; in a zero-decimal currency the same integer is 14,900 whole units.
How many decimal places the currency has, so amount_minor can be rendered without hard-coding a divisor: 2 for BRL and USD, 0 for JPY and CLP, 3 for KWD. null only if the stored code is one this API no longer prices in.
null on a one_time price.
day, week, month, year, null How many intervals between charges. null on a one_time price — never 0.
Whether amount_minor already contains tax. There is no third “undecided” value: the calculation belongs to the payment provider, but this input is yours and is answered when the price is created.
inclusive, exclusive No longer sold. Existing subscriptions keep it.
How this price is known at each payment provider. Empty means nothing can charge it yet. A price may be mapped onto more than one provider, and onto more than one account of the same provider.