Billing Portal service wrapping Stripe Billing Portal Sessions.
const session = await stripe.billingPortal.create({ customerId: 'cus_123', returnUrl: 'https://app.example.com/account',});redirect(session.url); Copy
const session = await stripe.billingPortal.create({ customerId: 'cus_123', returnUrl: 'https://app.example.com/account',});redirect(session.url);
Create a Billing Portal session for a customer.
Session creation options
The created session (use session.url to redirect the customer)
session.url
When customerId is missing
customerId
Billing Portal service wrapping Stripe Billing Portal Sessions.
Example