Documentation
Print page

Configuring a Payment Provider

SuperSaaS supports several payment providers to handle payments for appointments and for purchases in the credit shop. By default PayPal will be used as the payment provider. No specific configuration is needed for PayPal, the system will assume the administrator’s email address to be the PayPal account.

You can add one or more additional payment gateways and optionally remove PayPal as a provider with the instructions below. Configuration takes place by placing the word $gateway on the ‘Payment Setup’ page in the box “Message to show at the top of the shop page”.

Changing the default PayPal gateway

The PayPal gateway is enabled by default. If you intend to use a different gateway you may want to switch off the default PayPal gateway. This can be accomplished with this code:

$gateway{nopaypal}

By default the system will assume the administrator’s email address is linked to a PayPal account. You can instruct the system to use a different PayPal account by adding the following ‘magic word’:

$gateway{paypal email@example.com}

You can enable multiple gateways by adding multiple $gateway commands. If there is more than one payment gateway enabled, the customer will be able to choose.

Add Stripe as payment gateway

You can find comprehensive information about Stripe on their support page.

Stripe currently supports payments in more than 100 currencies and businesses registered in around 2 dozen countries can charge customers using Stripe. Stripe charges your customers in the currency that you configure on the “Payment Setup” screen.

If you already have a Stripe account, navigate to your Stripe Dashboard and open your “Account Settings”. In the “API Keys” section you will find 4 keys. The test keys are used for simulating payments without an actual money transfer, while the live keys are used for charging your customers.

You can easily start using Stripe with your SuperSaaS account with the following syntax:

$gateway{stripe sk_test_1234 pk_test_1234 sk_live_1234 pk_live_1234}

Replace the API keys in the above example with your API keys and Stripe will become visible as a payment option on the checkout screen.

Stripe API Keys

You can try out Stripe by switching to ‘Test Mode’ on the Payment Setup Screen in the Payment Settings section. Be aware that turning ‘Test Mode’ on, will switch all your currently configured payment providers to ‘Test Mode’. After making the first successful test payment, you can consult your Stripe Dashboard in ‘Test Mode’. If the payment is listed in the ‘Payments’ section, you can switch the ‘Test Mode’ off and start using Stripe in ‘Live Mode’.

Add ePay as payment gateway

There is also a Danish version of this guide

ePay is a Danish payment provider which supports a variety of payment methods, including Dankort. If you have an ePay account you can enable the ePay gateway using the following syntax:

$gateway{epay 123456}

Replace “123456” with the merchant ID you obtained from ePay. Furthermore, you will need to add the domain of your schedule in the ePay administrator setup. If the domain is not registered, you will get an error message. You can find this setting here: “Settings” → “Payment system” → “Domains created for relay-script”.

Typically you would enter “supersaas.dk” but if you use a custom domain name with SuperSaaS you would need to enter it there. If you enable SSL the domain name will always be “supersaas.com”. Furthermore, if you configure that the user will be redirected after a successful booking, the domain of that page needs to be added too. To add more than one domain you will need to contact ePay support. However, ePay does accept requests from sub-domains of the domain that is registered with them. So instead of registering multiple domains with ePay a workaround is to create a sub-domain for your schedule on the domain of the page that you are directing people to after booking. Using your own domain, or using SSL, can also prevent an issue where customers switch domain when they switch their language.

Enable the MD5 secret key

It is recommended that you enable an MD5 hash check on your account with a secret key. If there is no secret key present a hacker could spoof payment messages, causing appointments to be listed as paid when in reality no payment took place. To switch on the MD5 hash check use the following syntax:

$gateway{epay 123456 secret}

Replace “secret” with a word of your own choosing and enter the exact same word in your ePay administration screen here: “Settings” → “Payment system” → “Settings for the payment system” → “MD5 key”.

If the secret keys do not match exactly the system will move appointments to the trash, marking them with the message “Fraud check failed”, even if payment was successful.

Credit shop limitations for ePay

If you are using the credit shop, you will need to switch the setting “Unique orderID” to “Not using Unique orderID” on the “Settings for the payment system” page. Otherwise you would only be able to sell each product once, because the product ID is used as the order ID. When paying for appointments the order ID is a unique reservation number, so it’s fine to enable the setting in that case. Note that the feature to allow the customer to enter their own quantity is not available when using ePay.

Advanced ePay settings

If you use the same ePay account for multiple purposes you might like to create a separate “window”, which can have its own customization such as the logo. You can instruct the system to use a different window with this syntax: $gateway{epay 123456 secret 2}, where 2 is the window ID.

If you switch on “instant capture” the payment will automatically be captured right after the authorization step. You can enable instant capture by adding “1” as a fourth parameter, like this:

$gateway{epay 123456 secret 1 1}

Note that MD5 must be enabled to be able to set the window ID, and the window ID must be present to enable instant capture. If you do not know what a window ID is, you can simply use a 1.

Add Mollie as payment gateway

Logo iDeal, Mister Cash and Bitcoin Mollie is a Dutch payment provider that can be used to collect payments through the Dutch iDeal payment system and the Belgian Mister Cash system. It also has support for Bitcoin and the Sofort Banking system that’s popular in Germany. If you have a Mollie account you can enable the gateway using the following syntax:

$gateway {mollie test_abc123xyz live_abc123xyz}

You would replace the keys in the example with the API keys you can find inside your Mollie account on the “Website profiles” page. The Mollie button does not operate inside an iframe. If you want to run SuperSaaS inside an iframe you need to add JavaScript to the page where the button appears to allow the browser to “escape” from the frame. You can enter the JavaScript snippet shown below via the source code button (< >). This button is situated on the “Payment Setup” page for the shop and on the “layout” tab via the configuration settings for the schedule.

<script> if (window != top) top.location.href = location.href </script>

Add PayU as payment gateway

PayU is a payment provider for Poland and the Czech Republic. If you have a PayU account you can enable the gateway using the following syntax:

$gateway {payu 123456 second_key EUR}

You would need to replace the example number sequence “123456” with your actual POS ID which was provided to you by PayU when you signed up. You would also need to replace the example’s “second_key” with the actual second key from your PayU account. Finally, you need to enter the currency that you are using in PayU. Ensure that the currency configured on the Payment Setup screen in SuperSaaS is the same as the one in your PayU account.