Drop-in checkout
This example lets users pick between two price points (monthly or yearly) and starts a checkout with createCheckout(). The implementation includes:- Configuring SDK: Set up the SDK once with your
orgIdusingBilling.configure. - Creating checkout: Initialize a new checkout with
Billing.createCheckoutusing apriceIdand customer details (external ID and email). - Switching prices: Update the open checkout with
updatePrice()instead of creating a new one. - Event handling: Listen for success (redirect to confirmation page), error (display error message to user), and status changes (track checkout progress).
