Pricing
Configure fixed or variable pricing models for your subscriptions.
Overview
When creating a subscription, you define a price that determines how much to charge and how often. Subscriptions support two pricing models: fixed and variable.
Fixed pricing
A fixed amount is charged on each billing cycle. Set usage_type to fixed and provide the amount.
{
"usage_type": "fixed",
"amount": 19.99,
"currency": "GBP",
"cycle_details": {
"interval": "month",
"interval_count": 1,
"limit": 12
}
}Variable pricing
A different amount is charged on each billing cycle. Set usage_type to variable and provide a cycles array defining the amount for each cycle.
{
"usage_type": "variable",
"cycles": [
{ "cycle": 0, "amount": 20 },
{ "cycle": 1, "amount": 20 },
{ "cycle": 2, "amount": 19 }
],
"currency": "GBP",
"cycle_details": {
"interval": "month",
"interval_count": 1,
"limit": 3
}
}Cycle details
The cycle_details object controls the billing frequency and duration:
| Field | Description |
|---|---|
interval | The billing interval (e.g., day,week,month, year). |
interval_count | The number of intervals between each bill (e.g., 2 with month means every two months). |
limit | The maximum number of billing cycles. If omitted, the subscription continues indefinitely. |
NoteThe
limitfield withincycle_detailsis optional. If omitted, the subscription will continue indefinitely until cancelled via the API.
Updated about 6 hours ago