Aller au contenu principal

Prices

Prices define how much and how often to charge for products.

The Price object

{
"id": "price_abc123",
"object": "price",
"product": "prod_xyz789",
"unit_amount": 50000,
"currency": "xof",
"recurring": {
"interval": "month",
"interval_count": 1
},
"active": true,
"created": 1708300800
}

Endpoints

MethodEndpointDescription
POST/v1/pricesCreate a price
GET/v1/prices/{id}Retrieve a price
PATCH/v1/prices/{id}Update a price
GET/v1/pricesList prices

Create a Price

POST /v1/prices
ParameterTypeRequiredDescription
productstringProduct ID
unit_amountintegerAmount in smallest currency unit
currencystringThree-letter ISO currency code
recurringobjectFor recurring prices: { interval, interval_count }

Recurring intervals

IntervalDescription
dayDaily billing
weekWeekly billing
monthMonthly billing
yearAnnual billing