RestroPRO SaaS DocsInstallationStep Up Payment Gateway

Step 8: Setup Payment Gateway

RestroPro SaaS supports multiple payment gateways for subscription management. Configure your preferred gateway(s) below. You can enable Stripe (global) and/or Paystack (African markets) depending on your target regions.


Stripe

Stripe is a global payment gateway supporting multiple currencies and regions.

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.


Paystack

Paystack is optimized for African markets, supporting Nigerian Naira (NGN), Ghanaian Cedi (GHS), South African Rand (ZAR), Kenyan Shilling (KES), and other African currencies.

Step 1: Access Paystack 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 Paystack from the list of available payment gateways
  4. You will be presented with a form to configure Paystack credentials

Step 2: Get Paystack API Keys

  1. Create a Paystack Account:

    • If you don’t have a Paystack account, sign up at https://paystack.com
    • Complete the account verification process as required for your country
  2. Access API Keys:

    • Log in to your Paystack Dashboard at https://dashboard.paystack.com
    • Navigate to SettingsAPI Keys & Webhooks in the sidebar
    • You will see two sets of keys: Secret Key and Public Key
    • For testing, use the Test Secret Key and Test Public Key
    • For production, use the Live Secret Key and Live Public Key

Paystack API Keys and Webhooks

  1. Copy Your Keys:
    • Public Key: Starts with pk_test_ (test) or pk_live_ (live)
    • Secret Key: Starts with sk_test_ (test) or sk_live_ (live)
    • Click on the eye icon or “Reveal” button to view the secret key

Step 3: Configure Paystack Credentials in Super Admin

  1. In your Super Admin portal’s Paystack configuration form, paste your keys into:
    • Public Key: Your Paystack Public Key
    • Secret Key: Your Paystack Secret Key
    • Webhook URL: Copy this for the next step (automatically generated in the form)
  2. Use Test Keys during development; switch to Live Keys when going to production

Step 4: Set Up Paystack Webhook

  1. Copy Webhook URL: From the Paystack configuration form, copy the Webhook URL (e.g. https://api.yourdomain.com/api/v1/auth/paystack-webhook)
  2. Configure in Paystack Dashboard:
    • Go to Paystack Dashboard → SettingsAPI Keys & Webhooks
    • Scroll to the Webhooks section
    • Click Add Webhook URL or Add Webhook
    • Paste the webhook URL and save

Step 5: Complete Configuration and Enable Paystack

  1. Go back to your Super Admin portal Paystack configuration form
  2. Locate the Status toggle switch and Toggle it ON to enable Paystack
  3. Click Save or Update to save your configuration
⚠️

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


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