Stripe Payments

Ready to accept payments? Stripe is the world's leading payment platform, trusted by millions of businesses. Connect your Stripe account and the AI will build real, working payment flows for you โ€” no payment experience required!

๐ŸŽ‰ Real Payments, Not Demos! When you connect Stripe, the AI creates actual working checkout flows. You can test with Stripe's test cards, then go live when you're ready!

Stripe Payments Overview

Video coming soon

What Can You Build?

Payment TypeExample Use CaseExample Prompt
One-TimeSell a product or service"Add a buy button for a $29 ebook"
E-commerceShopping cart with multiple items"Add a checkout for the shopping cart"
SubscriptionsMonthly/yearly billing"Add subscription plans: $9/mo or $99/year"
DonationsAccept any amount"Add a donation form where users can enter any amount"

Getting Started: 4 Easy Steps

Step 1: Create a Free Stripe Account & Get Your API Keys

  1. Go to stripe.com
  2. Click "Start now" โ€” it's free to create an account
  3. Complete the basic signup (you can verify your identity later when going live)
  4. Go to dashboard.stripe.com/apikeys
  5. Copy your Secret key (starts with sk_test_)
  6. Copy your Publishable key (starts with pk_test_)
๐Ÿ’ก Test vs Live Keys: Stripe gives you two sets of keys. Start with test keys (sk_test_... and pk_test_...) for development. These let you test payments without real money. When you're ready to accept real payments, use your live keys.

Getting Your Stripe API Keys

Video coming soon

Step 2: Connect Supabase First

Important: Supabase must be connected before you can add Stripe. Edge Functions (which run on Supabase) are required for secure payment processing.

If you haven't connected Supabase yet, see the Supabase Integration guide first.

Step 3: Add Your Stripe Keys to Your Project

  1. Open your project in IndigiCoder
  2. Click the gear icon (โš™๏ธ) to open Project Settings
  3. Find the Stripe card
  4. Enter your Secret Key (from Step 1)
  5. Enter your Publishable Key (from Step 1)
  6. Click "Connect Stripe"
  7. Done! You'll see "Connected" with your key mode (Test or Live)
๐Ÿ”’ Your keys are secure: Your secret key is encrypted and stored securely. It's only used server-side when the AI creates checkout flows. Your publishable key is safe to use in client code (that's what it's designed for!).

Connecting Stripe to Your Project

Video coming soon

Step 4: Tell the AI What to Build

Now just describe what payments you want:

"Add a checkout button for my $49 online course"
"Add Stripe payments for the shopping cart"
"Add monthly subscription plans with a pricing page"

How It Works

The AI Creates Everything You Need

When you ask for payments, the AI automatically:

  • โœ… Creates products and prices in your Stripe account
  • โœ… Builds secure checkout using Stripe's hosted checkout page
  • โœ… Creates success and cancel pages
  • โœ… Sets up the backend (Edge Functions) to handle payments securely
  • โœ… Stores order/subscription data in your database

The Payment Flow

  1. Customer clicks "Buy" or "Subscribe"
  2. Redirected to Stripe's secure checkout (your site never sees card details)
  3. Customer enters payment info on Stripe
  4. Redirected back to your success page
  5. Order/subscription saved to your database
๐Ÿ”’ PCI Compliant by Default: Because we use Stripe's hosted checkout, your app never handles card numbers. Stripe takes care of all the security!

Understanding the Payment Flow

Video coming soon

Testing Your Payments

Use these test card numbers to simulate payments:

Card NumberResult
4242 4242 4242 4242โœ… Payment succeeds
4000 0000 0000 0002โŒ Card declined
4000 0025 0000 3155๐Ÿ” Requires 3D Secure

For expiry date, use any future date (e.g., 12/34). For CVC, use any 3 digits.

Important: These cards only work in Stripe's test mode. They won't charge real money!

Payment Scenarios Explained

Scenario 1: Simple One-Time Purchase

Best for: Digital products, services, one-off payments

"Add a buy button for my $29 ebook"
"Create a checkout for the $199 consulting session"

The AI creates a Stripe product with a fixed price and a simple checkout button.

Scenario 2: E-commerce (Shopping Cart)

Best for: Online stores with multiple products

"Add Stripe checkout for the shopping cart"
"Let customers buy multiple products at once"

The AI creates a cart-based checkout that supports multiple items with varying quantities. Prices come from your database.

Scenario 3: Subscriptions

Best for: SaaS, memberships, recurring billing

"Add subscription plans: Basic $9/month and Pro $29/month"
"Create a pricing page with monthly and annual options"

The AI creates recurring products, a pricing page, and sets up webhooks to track subscription status (renewals, cancellations, etc.).

โš ๏ธ Subscription Requirement: For subscriptions, you'll need to configure a webhook secret in Supabase. The AI will guide you through this โ€” it takes about 2 minutes. This is needed so Stripe can notify your app when subscriptions renew or cancel.

Scenario 4: Donations / Pay What You Want

Best for: Donations, tips, flexible pricing

"Add a donation form where users enter any amount"
"Create a tip jar with suggested amounts ($5, $10, $20) or custom"

The AI creates a dynamic checkout where customers choose their own amount.

Building Different Payment Types

Video coming soon

After Deployment

Payments work in the deployed version of your app, not in the preview. Here's what to expect:

Testing After Deployment

  1. Deploy your project to IndigiCoder or download and host elsewhere
  2. Visit your live site
  3. Click the checkout button
  4. Use test card 4242 4242 4242 4242
  5. Complete the payment โ€” you'll see it in your Stripe Dashboard!

Going Live (Real Payments)

When you're ready to accept real payments:

  1. Complete your Stripe account verification (identity, business details) in the Stripe Dashboard
  2. Go to dashboard.stripe.com/apikeys
  3. Copy your live keys (sk_live_... and pk_live_...)
  4. In your IndigiCoder project, open Project Settings (gear icon)
  5. Disconnect the current Stripe connection
  6. Reconnect with your live keys
  7. Redeploy your project
  8. You're now accepting real payments!
โš ๏ธ Before Going Live: Make sure you've tested everything thoroughly in test mode. Real payments mean real money!

Viewing Your Payments

All payments appear in your Stripe Dashboard. You can:

  • See all payments, subscriptions, and customers
  • Issue refunds
  • View analytics and reports
  • Export data for accounting
  • Manage disputes

Troubleshooting

Checkout isn't working in preview

That's expected! Stripe payments require deployment because they need a real server to process securely. Deploy your project first, then test.

I see "Stripe not connected"

Make sure you've connected Stripe in your Project Settings (gear icon). Also verify that Supabase is connected first โ€” Stripe requires Supabase for Edge Functions.

Payment succeeded but nothing saved to database

Make sure Supabase is also connected. The AI saves order data to your Supabase database. If Supabase isn't linked, there's nowhere to store the data!

Subscriptions not tracking renewals

You need to configure the webhook secret. The AI should have guided you through this. Go to your Stripe Dashboard โ†’ Developers โ†’ Webhooks and make sure the endpoint is set up.

Troubleshooting Stripe Payments

Video coming soon

Frequently Asked Questions

What fees does Stripe charge?

Stripe charges 2.9% + 30ยข per successful card payment (in the US). There are no monthly fees. See Stripe's pricing for details.

Can I offer discounts or coupons?

Yes! Just ask the AI: "Add a coupon code field to checkout". You'll create the actual coupon codes in your Stripe Dashboard.

How do refunds work?

Issue refunds directly in your Stripe Dashboard. The AI can also add refund functionality to your app if you ask.

Do I need Supabase for Stripe?

Technically no, but we highly recommend it. Without Supabase, there's no database to store orders or track subscription status. Most payment features work best with both connected.

Is my customer's payment info secure?

Absolutely! Your app never sees credit card numbers. Customers enter payment details directly on Stripe's PCI-compliant checkout page. Your Stripe keys are encrypted in IndigiCoder and never exposed in client code.

Stripe Integration FAQ

Video coming soon

Stripe Payments - Documentation | IndigiCoder