RestroPRO SaaS DocsInstallationStep Up Payment Gateway

Step 8: Setup Payment Gateway

Step 1: Access Stripe Configuration

  1. Navigate to your Super Admin portal at https://yourdomain.com/superadmin/dashboard/payment-gateways and log in with your Super Admin credentials
  2. In the Super Admin dashboard, locate and click on Payment Gateways in the navigation menu
  3. Click on Stripe from the list of available payment gateways
  4. You will be presented with a form to configure Stripe credentials

image

Step 2: Get and Configure Stripe API Keys

  1. Log in to your Stripe Dashboard at https://dashboard.stripe.com.
  2. Switch to the correct mode (Test or Live) as needed.
  3. Go to DevelopersAPI keys in the sidebar, and copy your Publishable key and Secret key (use “Reveal” to view the secret key).
  4. In your Super Admin portal’s Stripe configuration form, paste both keys into their respective fields.
  5. Copy the Webhook URL from the same form for use in the next step.

Step 3: Set Up Stripe Webhook

  1. Go back to your Stripe Dashboard and navigate to DevelopersWebhooks in the left sidebar
  2. Click on Add endpoint button
  3. Paste the webhook URL you copied from the Super Admin portal into the Endpoint URL field
  4. In the Events to send section, select the following events:
    • customer.subscription.created
    • customer.subscription.updated
    • customer.subscription.deleted
    • invoice.payment_succeeded
    • invoice.payment_failed
    • customer.subscription.trial_will_end
    • checkout.session.completed
  5. Click on Add endpoint to save the webhook
  6. Once the webhook is created, click on the webhook endpoint you just created
  7. In the Signing secret section, click on Reveal or Click to reveal
  8. Copy the Signing secret (it starts with whsec_)

image

Step 4: Complete Configuration and Enable Stripe

  1. Go back to your Super Admin portal Stripe configuration form
  2. Paste the Webhook Secret you copied from Stripe Dashboard into the Webhook Secret field
  3. Locate the Status toggle switch and Toggle it ON to enable the Stripe payment gateway
  4. Click on Save or Update to save your configuration
⚠️

Make sure the toggle is ON (enabled) for Stripe payment gateway to be active. If the toggle is OFF, the payment gateway will not process payments.

Note: If you have already added a plan and you change anything in the payment gateway settings, it is your responsibility to ensure that all payment configurations and plans remain correct and functional. Always double-check your plans and payment settings after making changes.

Below version v2.0.0 (Legacy)

1.0 Stripe Credentials
  • To configure subscriptions for the app, follow the mentioned steps & then get your stripe credentails - STRIPE_SECRET & STRIPE_WEBHOOK_SECRET as required.
1.1 Stripe Subscription Setup
  • Goto Stripe and set up your account according to your business registration type. Once you activate your account, follow the given procedure.
  • Goto Stripe Dashboard and Select “Product catalogue”, then Add new product. image
  • Fill the details as per your business requirements. image
  • Once you create the Subscription Product, you will see it like this. image
  • Now go back to Stripe Dashboard and open the developers page, you will get API keys from there. Look for a secret key, and copy it. This will be your STRIPE_SECRET. image
  • Now we will set up the webhook. For that open Stripe Dashboard and goto developers page again. Goto Webhooks Tab, then click on Add endpoint. image
  • Then provide the webhook URL, this will be our backend route webhook handler, so we’re yet to setup the backend, so you just need to provide the url. For example if i’m setting Backend on domain “api.example.com” then the webhook URL will look like this.Webhook URL: https://api.example.com/api/v1/auth/stripe-webhook. Replace the domain, to your backend domain. After placing endpoint URL, click on the ‘select events to listen to’ image
  • Look for the following events and select them. image
  • Once you add it open the created webhook endpoint in Stripe Dashboard.
  • Click on the ‘Reveal’ to copy the Webhook Signing Secret. image
  • Paste the copied secret in STRIPE_WEBHOOK_SECRET
STRIPE_SECRET=YOUR_STRIPE_SECRET
STRIPE_WEBHOOK_SECRET=YOUR_STRIPE_WEBHOOK_SECRET