Skip to main content
Called when a user builds a custom plan by selecting individual features.

Endpoint

POST /api/stripe/checkout/custom

Body

shareId
string
required
Your project’s Share ID
selectedFeatures
string[]
required
Array of feature names the user selected
email
string
Customer email
subscriptionDuration
string
"monthly", "3months", "6months", "9months", or "12months"
userCount
number
Number of users (for per-user pricing)
featureUsageAmounts
object
Usage amounts per feature. Keys are feature names, values are quantities.

Example request

{
  "shareId": "nTZ7axXQHU",
  "selectedFeatures": ["AI Prompt", "Dashboard"],
  "email": "user@example.com",
  "subscriptionDuration": "monthly",
  "userCount": 1,
  "featureUsageAmounts": {
    "API Calls": 500
  }
}

Response

{
  "url": "https://checkout.stripe.com/c/pay/cs_live_..."
}

Metadata stored

The checkout session stores feature details in metadata for later retrieval via the Receipt API:
{
  "customPlan": "true",
  "projectId": "203",
  "featureDetails_0": "[{\"name\":\"AI Prompt\",\"price\":10,...}]"
}