Skip to content

Preview the Stripe subscription price

Request

Generates a preview of the total price and tax amount that Stripe will charge the customer if they create a new subscription for the specified plan.

Note: This method does not create any entities in Stripe and does not result in any payments being made.

Security
CookieBlaizeSession or JwtQuery or JwtHeaderXBlaizeJwt or JwtHeaderXZephrJwt or JwtBearer or JwtCookie
Bodyapplication/json
product_idstringrequired

The ID of the new Zephr product.

Example:"zephr-prod-1"
plan_idstringrequired

The new Stripe price plan ID.

Example:"price_H8eIeMFwMawg6w"
promo_codestring

The Stripe promo code that will be attached to the subscription.

Example:"discount15"
billing_countrystring

The user's billing country, for tax calculation purposes.

Example:"US"
billing_post_codestring

The user's billing postal code, for tax calculation purposes.

Example:"90210"
{ "product_id": "zephr-prod-1", "plan_id": "price_H8eIeMFwMawg6w", "promo_code": "discount15", "billing_country": "US", "billing_post_code": "90210" }

Responses

OK

Headers
any
Body*/*
totalnumber

The total amount the user will be initially charged for the subscription in the relevant currency's lowest denomination (e.g. pence), i.e. for a monthly subscription, the first month's cost.

Example:5000
sub_totalnumber

The total amount minus tax for the initial charge in the relevant currency's lowest denomination (e.g. pence).

Example:4500
taxnumber

The tax amount for the initial charge in the relevant currency's lowest denomination (e.g. pence).

Example:500
discountnumber

The discount amount for the initial charge in the relevant currency's lowest denomination (e.g. pence).

Response
{
  "total": 5000,
  "sub_total": 4500,
  "tax": 500,
  "discount": 0
}