v2

latestOpenAPI 3.1.02026-08-054181117.0 KB

Create Stripe Checkout Session

Create a Stripe Checkout Session for purchasing credits with Isometric verification. This endpoint returns a Stripe Checkout URL to redirect the user to for completing the payment.

post/stripe/checkout

Headers

x-client-secretstring required

A secret token identifying the client connecting to the API

Example:Syou3EZiO5vuMEgNyBeA8cjEMYOnQDwP

A secret token identifying the client connecting to the API

Request body

quantity_kginteger required

The quantity of credits to purchase, in kilograms. This field can handle bigint values.

frequency'one_time' | 'monthly' | 'yearly' required
isometric_terms_and_conditions_acceptedboolean required

Whether the user has accepted the Isometric terms and conditions; the request will fail if this is not set to true

supplier_terms_and_conditions_acceptedboolean required

Whether the user has accepted the supplier terms and conditions; the request will fail if this is not set to true

customer_emailstring nullable

The email of the customer to prefill the checkout session with. If not provided, the customer will be prompted to enter their email during checkout.

success_urlstring required

The URL to redirect customer to after a successful payment

cancel_urlstring required

The URL to redirect customer to after a cancelled or failed payment

Example request

{
  "quantity_kg": 1000,
  "isometric_terms_and_conditions_accepted": true,
  "supplier_terms_and_conditions_accepted": true,
  "customer_email": "test@example.com",
  "success_url": "https://example.com/success",
  "cancel_url": "https://example.com/cancel"
}

Response

Successful Response

redirect_urlstring required