Create price
This endpoint is used to create a price. A price created using this endpoint is always an add-on, meaning that it’s not associated with a specific plan and can instead be individually added to subscriptions, including subscriptions on different plans.
An external_price_id
can be optionally specified as an alias to allow ergonomic interaction with prices in the Orb API.
See the Price resource for the specification of different price model configurations possible in this endpoint.
Authorizations
API Keys can be issued in the Orb's web application.
Body
The cadence to bill for this price on.
annual
, semi_annual
, monthly
, quarterly
, one_time
, custom
An ISO 4217 currency string for which this price is billed in.
The id of the item the plan will be associated with.
unit
The name of the price.
The id of the billable metric for the price. Only needed if the price is usage-based.
If the Price represents a fixed cost, the price will be billed in-advance if this is true, and in-arrears if this is false.
For custom cadence: specifies the duration of the billing period in days or months.
The per unit conversion rate of the price currency to the invoicing currency.
An alias for the price.
If the Price represents a fixed cost, this represents the quantity of units applied.
The property used to group this price on an invoice
Within each billing cycle, specifies the cadence at which invoices are produced. If unspecified, a single invoice is produced per billing cycle.
User-specified key/value pairs for the resource. Individual keys can be removed by setting the value to null
, and the entire metadata mapping can be cleared by setting metadata
to null
.
Response
The Price resource represents a price that can be billed on a subscription, resulting in a charge on an invoice in the form of an invoice line item. Prices take a quantity and determine an amount to bill.
Orb supports a few different pricing models out of the box. Each of these models is serialized differently in a given Price object. The model_type field determines the key for the configuration object that is present.
For more on the types of prices, see the core concepts documentation
one_time
, monthly
, quarterly
, semi_annual
, annual
, custom
User specified key-value pairs for the resource. If not present, this defaults to an empty dictionary. Individual keys can be removed by setting the value to null
, and the entire metadata mapping can be cleared by setting metadata
to null
.
unit
usage_price
, fixed_price
Was this page helpful?