Skip to main content
Who should use this guideThis guide is intended for merchants who:
  • Use Payrails as a payment orchestrator
  • Use Payflex to offer buy now, pay later in South Africa
  • Have an active Payflex merchant account with API credentials

Create a Payflex integration in Payrails

  1. Log in to the Payrails portal.
  2. Go to Settings → Integrations.
  3. Select Add instance to create a new integration configuration.
  4. Select the workspaces where this integration should be available.
About workspacesWorkspaces determine where this integration is available. They let you isolate provider setups by region or business line, or share the same configuration across multiple workspaces.

Step 1: Choose the integration type

  • Select Payment.
  • Continue to the next step.

Step 2: Choose the provider

  • Select Payflex.
  • Continue to the next step.
A screenshot showing Payflex selected as the provider.

Step 3: Configure your Payflex integration

What you’ll need from PayflexBefore you begin, make sure you have your Payflex client ID and client secret. Payflex provides them when it sets up your merchant account.

Integration instance name

An integration instance is a specific payment provider setup in Payrails. You can create multiple instances for different regions, currencies, or business needs. Choose a clear, consistent name, as it is used in routing.
In Payrails
  • Enter an Instance name for your integration, for example merchant_payflex.
A screenshot showing the integration instance name field.

Credentials

In Payrails Payrails exchanges these for an access token with every request. It sends requests to the Payflex UAT environment in test mode and to the live environment in live mode, so use the credentials for the matching environment. A screenshot showing the Payflex credential fields.

Payment methods

In Payrails
  • Select Payflex.
A screenshot showing the Payflex payment method selection.

Webhooks or notifications

Payrails sends its notification URL to Payflex with every payment, so you don’t need to set one up in the Payflex dashboard. Payrails confirms each notification by checking the order with Payflex.

Request fields for Payflex

Send these fields in the authorize request, in addition to the standard authorize fields. Required fields must be present for the payment to succeed. Payrails sends Optional fields to Payflex when you include them. For more about meta fields, refer to Meta fields. When you send meta.order, the order lines, shipping, tax and discounts must add up to amount.

Enable the integration

In Payrails
  • Select Save account to enable the integration.
  • Confirm the integration shows as Enabled.
Your Payflex integration is now ready to process payments.

Next steps

  1. Run a test Payflex payment in ZAR in the Payflex UAT environment.
  2. Verify that:
    • The order appears in Payflex.
    • The payment status updates correctly in Payrails.
  3. Once verified in test mode, repeat the setup in live mode.
→ Continue to: Test a payment
Last modified on October 6, 2026