logo
Custom Server Environment

Payment Gateways

Integrating Payment Gateways

Framecast AI supports six payment gateways out of the box:

You can enable one or all of them depending on your target audience and region.

Stripe

Get Your Stripe Keys

Log in to your Stripe Dashboard and navigate to the API keys section. Make sure you are in Live mode (not test mode). You will need your Publishable Key and Secret Key.

Set Up Webhook

Create a new webhook endpoint in Stripe Webhooks pointing to:

https://your-domain.com/api/payment-gateways/stripe/subscription-webhook

Replace your-domain.com with your actual server domain. Add the following events to the webhook:

  • checkout.session.completed, processes credit purchases (primary event)
  • charge.succeeded
  • payment_intent.succeeded
  • payment_intent.created
  • charge.updated
  • product.created
  • price.created

Copy the webhook signing secret after creating the endpoint.

Update Your .env File

NEXT_PUBLIC_STRIPE_IS_ENABLED=true
STRIPE_PUBLISHABLE_KEY=your-stripe-publishable-key
STRIPE_SECRET_KEY=your-stripe-secret-key
STRIPE_WEBHOOK_SECRET=your-stripe-webhook-secret

Pricing packages and credit amounts are fully configurable from the Admin Panel. No need to manually create Stripe products or price IDs.

PayPal

Create a PayPal App

Log in to the PayPal Developer Dashboard and select Apps & Credentials. Make sure you are in Live mode. Create a new app to get your Client ID and Client Secret.

Update Your .env File

PAYPAL_API_URL=https://api-m.paypal.com
NEXT_PUBLIC_PAYPAL_CLIENT_ID=your-paypal-client-id
PAYPAL_CLIENT_SECRET=your-paypal-client-secret

For production, use https://api-m.paypal.com. If you need to test first, use https://api-m.sandbox.paypal.com and switch to the production URL before going live.

Razorpay

Get Your Razorpay Keys

Log in to your Razorpay Dashboard and navigate to Account & Settings then API Keys under Website and App Settings. Make sure Live mode is enabled. Generate a new key pair.

Update Your .env File

NEXT_PUBLIC_RAZORPAY_KEY_ID=your-razorpay-key-id
RAZORPAY_KEY_SECRET=your-razorpay-key-secret

Flutterwave

Get Your Flutterwave Keys

Log in to your Flutterwave Dashboard and make sure you are in Live mode. Navigate to Settings then API Keys. You will need your Public Key, Secret Key, and Encryption Key.

Update Your .env File

NEXT_PUBLIC_FLUTTERWAVE_PUBLIC_KEY=your-flutterwave-public-key
FLUTTERWAVE_SECRET_KEY=your-flutterwave-secret-key
FLUTTERWAVE_ENCRYPTION_KEY=your-flutterwave-encryption-key

Paddle

Get Your Paddle Keys

Log in to your Paddle Dashboard and go to Developer tools > Authentication to copy your API key and client-side token. Open Developer tools > Webhooks and create a webhook endpoint.

Approve Your Checkout Domain

Add your production domain in Checkout > Domain approval, and set it as the Default payment link under Checkout > Checkout settings.

Map Prices to Packages

Create one one-time price per billing package, then map each paddlePriceId under Admin > Billing Packages.

Set Up Webhook

Point the webhook to your production URL:

https://your-domain.com/api/payment-gateways/paddle/webhook

Add the transaction.completed event and copy the signing secret.

Update Your .env File

NEXT_PUBLIC_PADDLE_ENV=production
NEXT_PUBLIC_PADDLE_CLIENT_TOKEN=your-paddle-client-token
PADDLE_API_KEY=your-paddle-api-key
PADDLE_WEBHOOK_SECRET=pdl_ntf_your-paddle-webhook-secret

Dodo Payments

Get Your Dodo Keys

Log in to your Dodo Payments Dashboard and open Settings > API Keys to copy your API key. Create your webhook endpoint in Webhooks and copy its signing key.

Map Products to Packages

Create one one-time product per billing package, then map each dodoProductId under Admin > Billing Packages.

Set Up Webhook

Point the webhook to your production URL:

https://your-domain.com/api/payment-gateways/dodo/webhook

Add the payment.succeeded event and copy the webhook signing key.

Update Your .env File

NEXT_PUBLIC_DODO_ENV=live_mode
DODO_PAYMENTS_API_KEY=your-dodo-api-key
DODO_PAYMENTS_WEBHOOK_KEY=your-dodo-webhook-key