Skip to main content
PUT
Update credit portal settings

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string
required
productId
string
required

Body

application/json

Credit portal settings

enabled
boolean
required

Whether the customer can buy this credit product from the customer portal. Enabling requires a price: price_configuration_id, custom_price_configuration, or the price already set. Disabling clears the price and removes the customer's own price.

Example:

true

price_configuration_id
string

ID of one of the credit product's price configurations, in the customer's price book and currency, of type bundle, volume or bulk. Mutually exclusive with custom_price_configuration.

Example:

"prc_3kXODDF42QXtnL"

custom_price_configuration
Volume · object

A price of the customer's own, in the customer's currency, replacing any previous one. Same shape as a credit product price configuration. Mutually exclusive with price_configuration_id.

Response

200 - application/json

Credit portal settings after the update

customer_id
string
required

Customer ID related to the credit.

Example:

"cus_Typ0px2W0aiEtl"

product_id
string
required

Credit product ID.

Example:

"itm_3kXODDF42QXtnL"

enabled
boolean
required

Whether the customer can buy this credit product from the customer portal. Enabling requires a price: price_configuration_id, custom_price_configuration, or the price already set. Disabling clears the price and removes the customer's own price.

Example:

true

currency
string | null
required

Customer currency, which every portal price must use.

Example:

"EUR"

price_configuration
Fee · object
required

Price configuration the customer pays on the portal. null while disabled, or once that price configuration is archived, deleted or not in the customer's currency.

is_custom_price
boolean
required

Whether price_configuration is the customer's own price.

Example:

false