How It Works

Understand the complete purchase flow from customer discovery to user provisioning in your application.

The Purchase Flow

1 2 3 4 Customer (Buyer) S Sumo (Marketplace) Your Stripe (Connected) Your App (Your SaaS) Browse Checkout Creates checkout session with Sumo metadata Sends webhook to your endpoint Webhook You handle: 1 Create user 2 Link subscription 3 Provision access

Step-by-Step Breakdown

1

Customer Discovers Your Product

A customer browses Sumo Marketplace and finds your product listing. They review your pricing tiers, features, and decide to purchase a lifetime discount.

2

Sumo Creates Checkout Session

When the customer clicks "Buy", Sumo creates a Stripe Checkout session on your connected Stripe account. This session includes special metadata:

{
  "sumo_campaign_id": "camp_abc123",
  "sumo_product_id": "prod_xyz789",
  "sumo_product_tier_id": "tier_456",
  "sumo_user_id": "user_def",
  "sumo_quantity": "1"
}
3

Stripe Sends Webhook

After successful payment, Stripe sends a checkout.session.completed webhook to your endpoint. This webhook contains all the checkout data including Sumo's metadata.

4

Your App Provisions Access

Your webhook handler detects the Sumo metadata and performs user provisioning:

  • Create or find user account by email
  • Link the Stripe subscription to the user
  • Grant access to features based on the tier
  • Send welcome email with login instructions

Key Insight

The purchase happens on your Stripe account, not Sumo's. You receive the same webhooks you'd get from any Stripe purchase. The only difference is that Sumo created the checkout session with special metadata to identify the purchase source.

Continue to Implementation