Checkout

Create a customer and product, then a checkout session and get a clickable checkout_url.

import Lumn from '@lumnsh/stripe';
const lumn = new Lumn(process.env.NEXT_PUBLIC_LUMN_API_KEY);
const customer = await lumn.customers.create({
external_id: 'user_' + Date.now(),
email: 'demo@example.com',
name: 'Demo User',
});

Step 1 - Create customer (customers.create)

Parameter reference
ParameterTypeRequiredDescriptionExample
external_idstringRequiredCustomer identifier in your system (recommended: stable + unique).`user_${Date.now()}`
emailstringRequiredCustomer email (useful for display and reconciliation).demo@example.com
namestringRequiredCustomer display name.Demo User

Interactive UI & Output

Paste your API key above to try

Customize parameters

Provide an existing customer & product to skip creation steps and go straight to checkout.