A valid request URL is required to generate request examples{
"id": "<string>",
"object": "price",
"product_id": "<string>",
"merchant_id": "<string>",
"unit_amount": 123,
"currency": "<string>",
"type": "one_time",
"active": true,
"nickname": "<string>",
"metadata": {},
"livemode": true,
"created_at": 123,
"updated_at": 123,
"recurring": {
"interval": "day",
"interval_count": 123,
"usage_type": "licensed"
}
}{
"error": {
"code": "INVALID_REQUEST",
"message": "invalid request body"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "PRODUCT_NOT_FOUND",
"message": "product not found"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}Create a price
Creates a new price attached to a product. The unit_amount and currency are
immutable after creation. Supply recurring to create a recurring price; omit it
for a one-time price. Set make_default: true to atomically designate this price
as the product’s default at creation time.
A valid request URL is required to generate request examples{
"id": "<string>",
"object": "price",
"product_id": "<string>",
"merchant_id": "<string>",
"unit_amount": 123,
"currency": "<string>",
"type": "one_time",
"active": true,
"nickname": "<string>",
"metadata": {},
"livemode": true,
"created_at": 123,
"updated_at": 123,
"recurring": {
"interval": "day",
"interval_count": 123,
"usage_type": "licensed"
}
}{
"error": {
"code": "INVALID_REQUEST",
"message": "invalid request body"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "PRODUCT_NOT_FOUND",
"message": "product not found"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}Authorizations
A merchant secret key (sk_…) sent as Authorization: Bearer <key>.
Headers
Merchant ID when an authorized Platform acts for a connected Merchant. Omit when authenticating directly as that Merchant.
^mer_[0-9A-Za-z]{14}$A unique key that makes retries safe: the same key with the same request body returns the original response instead of repeating the operation.
255Body
The product this price belongs to (prod_…).
Billing amount in minor units (e.g. cents for USD).
Three-letter ISO currency code (e.g. USD).
Price type. Inferred from whether recurring is present when omitted.
one_time, recurring Display label for this price variant.
Custom key-value metadata. Max 50 keys; keys up to 40 characters; values up to 500 characters.
Show child attributes
Show child attributes
If true, atomically set this price as the product's default after creation.
Cadence for recurring prices. Omit for one-time prices.
Show child attributes
Show child attributes
Response
The created price.
Price id (price_…).
price Parent product (prod_…).
ID of the account that owns the price (mer_…).
Billing amount in minor units.
Three-letter ISO currency code.
Price type.
one_time, recurring false when the price is deactivated.
Display label for this price variant.
Custom key-value pairs for your use.
Show child attributes
Show child attributes
true for live mode, false for test mode.
Unix epoch seconds.
Unix epoch seconds.
Cadence for recurring prices; null for one-time prices.
Show child attributes
Show child attributes

