Payfast.co.za payments

Payfast is a Splynx add-on which allows refilling of customer balances and paying invoices via the PayFast payment gateway.

We've developed two different add-ons for using this payment system: splynx-payfast and splynx-payfast-rb. The first add-on - splynx-payfast is used for payments which proceed only in the PayFast system. The second add-on - splynx-payfast-rb can work with different credit-cards using PayFast and allows you to charge all customers by using Direct debit order.

WARNING! PayFast makes use of ports 80, 8080, 8081 and 443 only. So your Splynx Url has to be on the same ports!

The add-ons can be installed in two method, via the CLi or the Web UI of your Splynx server.

splynx-payfast

To install the splynx-payfast add-on via CLie, the following commands can be used:

apt-get update
apt-get install splynx-payfast

To install it via the Web UI:

Navigate to Config → Integrations → Add-ons:

Addons

Locate or search for the splynx-payfast add-on and click on the install icon in the Actions column

Integrations addons

Click on the "OK, confirm" button to begin the installation process

Integrations addons 2

After the installation process has completed, you have to configure the parameters in Config → Integrations → Modules list.

Locate or search for the splynx-payfast add-on and click on edit in the Actions column,

you will be presented with the following window

Edit params

Merchant details

NAME DESCRIPTION
merchant_id The Merchant ID as given by the PayFast system. Used to uniquely identify the receiving account. This can be found on the merchant’s settings page.
merchant_key The Merchant Key as given by the PayFast system. Used to uniquely identify the receiving account. This provides an extra level of certainty concerning the correct account as both the ID and the Key must be correct in order for the transaction to proceed. This can be found on the merchant’s settings page.

Thereafter, customers can pay for their invoices and refill their balances using the PayFast system. Customers will see a new icon to pay as depicted below:

Pay invoice

Customers can also refill their balances using the following link - “https:///payfast”.

Add amount

When clicking on the Pay button, you will be redirect to https://payfast.co.za and you’ll need to complete your payment:

Complete payment

splynx-payfast-rb

To install the splynx-payfast-rb add-on via CLI, the following commands can be used:

apt-get update
apt-get install splynx-payfast-rb

To install it via the Web UI:

Navigate to Config → Integrations → Add-ons:

Integrations addons PF rb

Thereafter, you need to log into your account on https://www.payfast.co.za/ and enable Subscription state and Ad hoc payments state:

3.1.png

Also, it's necessary to set your Notify Url, e.g. https:///payfast-rb/notify, when the successful payment is made, PayFast will send an Instant Transaction Notifications (payment confirmation) to this url before a customer gets redirected to return_url:

Notify Url

More info related to recurring billing integration is here

Once these options were configured, you have to configure the parameters in Config → Integrations → Modules list as depicted below:

Integrations addons PF rb 2

Edit params PF rb

Customers will see another icon to pay in the customer portal, as depicted below:

Pay invoice rb

To refill balances, customers can use the following link - “http:///payfast-rb”, where they have to enter their registration details for the first time:

Add payfast account rb

You can also charge all customers using one button! Navigate to: Finance → Invoices, set the period and click on Charge as depicted below:

charge

charge

Direct payments using PayFast and PayFast-RB

Using the payments links is the simplest way to accept payments made with credit card. This feature is available in the PayFast and PayFast-RB addons to pay Invoices and Proforma Invoices. This provides convenience and simplicity for your customer, so the amount of on-time payments will increase. For example, you can add a payment link to the e-mail with the (proforma) invoice, as a result, the customer can make payment quickly by clicking onto this link instead of logging in to their Portal page. In case the customer has saved the card details on the Portal, they do not need to add further details when using the direct payment link in the future. If the credit card in not linked on the Portal, the payment details need to be entered each time the payment link is used.

To create a direct payment link, please use the patterns below:

for PayFast

To pay the Invoice:

by invoice ID
https://<splynx_domain_address>/payfast/direct-pay-invoice-by-id?item_id=<invoice_id>

To pay the Proforma Invoice:

by proforma invoice ID
https://<splynx_domain_address>/payfast/direct-pay-proforma-by-id?item_id=<proforma_id>

for PayFast-RB

To pay the Invoice:

by invoice ID
https://<splynx_domain_address>/payfast-rb/direct-pay-invoice-by-id?item_id=<invoice_id>

To pay the Proforma Invoice:

by proforma invoice ID
https://<splynx_domain_address>/payfast-rb/direct-pay-proforma-by-id?item_id=<proforma_id>