Day 04 Platform Payouts

Stripe Connect: Paying Third-Party Sellers

If your platform takes a cut and pays out to others — a marketplace, freelance platform, or SaaS with affiliate payouts — Stripe Connect is how you do it. Today you create a Connect account, flow money through your platform, and split fees automatically.

~1 hour Intermediate Hands-on Precision AI Academy

Today's Objective

Create a Stripe Connect Express account, process a payment that routes funds to the connected account, and capture your platform's fee in a single API call.

A marketplace is not just a payment processor — it is a financial intermediary. Stripe Connect handles the regulatory complexity of moving money between parties so you can build the product without becoming a payment processor.

01

Connect Account Types

Stripe Connect offers three account types for different ownership models:

Express / Standard

Seller-Owned Accounts

Sellers create and manage their own Stripe accounts. Express gives you a streamlined onboarding UI. Standard gives sellers full Stripe dashboard access. Use for marketplaces where sellers accept their own liability.

Custom

Platform-Owned Accounts

Your platform owns the Stripe account; sellers never interact with Stripe directly. Maximum control, maximum compliance responsibility. Use for platforms that need white-label payment UX.

Start with Express. It handles KYC, identity verification, and bank account collection for you. Custom requires significant compliance and legal work.
02

Seller Onboarding with Account Links

Generate an Account Link to redirect sellers to Stripe's hosted onboarding UI. Stripe handles identity verification, bank account collection, and Terms of Service acceptance.

onboard_seller.js
JavaScript
// 1. Create a connected account
const account = await stripe.accounts.create({ type: 'express' });
await db.saveSeller({ stripeAccountId: account.id });

// 2. Generate onboarding link
const link = await stripe.accountLinks.create({
  account:     account.id,
  refresh_url: `\${DOMAIN}/onboard/refresh`,
  return_url:  `\${DOMAIN}/onboard/complete`,
  type:        'account_onboarding',
});

res.redirect(303, link.url);
03

Destination Charges and Platform Fees

A destination charge processes the full amount on the platform's account and automatically transfers a portion to the connected seller, minus your platform fee.

destination_charge.js
JavaScript
const session = await stripe.checkout.sessions.create({
  payment_method_types: ['card'],
  line_items: [{ price_data: {
    currency: 'usd',
    product_data: { name: 'Service booking' },
    unit_amount: 10000,
  }, quantity: 1 }],
  mode: 'payment',
  payment_intent_data: {
    application_fee_amount: 1000,     // $10 platform fee
    transfer_data: {
      destination: sellerStripeAccountId,  // seller gets $90
    },
  },
  success_url: `\${DOMAIN}/success`,
  cancel_url:  `\${DOMAIN}/cancel`,
});

Supporting Videos & Reading

Go deeper with these external references.

Day 4 Checkpoint

Before moving on, you should be able to answer these without looking:

Continue To Day 5
Testing, Errors & Going Live