curl --request POST \
--url https://api.kelviq.com/api/v1/checkout/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"planIdentifier": "plan-pro-monthly",
"successUrl": "https://kelviq.com/checkout/success",
"chargePeriod": "MONTHLY",
"customerId": "cust_789",
"features": [
{
"identifier": "seats",
"quantity": 5
}
],
"ipAddress": "103.154.35.20"
}
'{
"checkoutUrl": "https://checkout.stripe.com/c/pay/cs_test_b1sNi7D6u9iMCUFV1UZi9ZaiXKdOOmr3DCUW6XdCZIr5Id1F7#fid...",
"checkoutSessionId": "cs_test_b1sNi7D6u9iMCUFV1UZi9ZwerfaiXKdOOmr3DCUW6XdCZIr5Id1F7G"
}Creates a new checkout session for a customer to proceed with a purchase or subscription.
curl --request POST \
--url https://api.kelviq.com/api/v1/checkout/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"planIdentifier": "plan-pro-monthly",
"successUrl": "https://kelviq.com/checkout/success",
"chargePeriod": "MONTHLY",
"customerId": "cust_789",
"features": [
{
"identifier": "seats",
"quantity": 5
}
],
"ipAddress": "103.154.35.20"
}
'{
"checkoutUrl": "https://checkout.stripe.com/c/pay/cs_test_b1sNi7D6u9iMCUFV1UZi9ZaiXKdOOmr3DCUW6XdCZIr5Id1F7#fid...",
"checkoutSessionId": "cs_test_b1sNi7D6u9iMCUFV1UZi9ZwerfaiXKdOOmr3DCUW6XdCZIr5Id1F7G"
}The Server API Key obtained from the kelviq application. Pass as a Bearer token in the Authorization header. Example: 'Authorization: Bearer YOUR_API_KEY'
The identifier of the specific plan the customer is checking out with.
"plan-pro-monthly"
The URL to which the user will be redirected after a successful checkout.
"https://kelviq.com/checkout/success"
The billing cycle for the subscription.
ONE_TIME, MONTHLY, YEARLY, WEEKLY, DAILY, THREE_MONTHS, SIX_MONTHS "MONTHLY"
The ID of the customer initiating the checkout. If not provided, a new customer may be created depending on server logic.
Note: Even if a unique customer ID is provided, if the email address already exists in the system, the subscription will be created for that existing email — not the new customer ID. This is to preserve the uniqueness of the email address.
"cust_789"
A list of features and their desired quantities. SDK documentation notes this as 'Required', but usage may vary based on examples.
Show child attributes
[{ "identifier": "seats", "quantity": 5 }]The IP Address of the customer, used for location-based pricing.
"103.154.35.20"
Checkout Session Created
The URL that the customer should be redirected to complete the payment.
"https://checkout.stripe.com/c/pay/cs_test_b1sNi7D6u9iMCUFV1UZi9ZaiXKdOOmr3DCUW6XdCZIr5Id1F7#fid..."
The unique ID for the created checkout session.
"cs_test_b1sNi7D6u9iMCUFV1UZi9ZwerfaiXKdOOmr3DCUW6XdCZIr5Id1F7G"