Articles on: Vouchers

Can I setup my own local payment provider to accept payments in vouchers?

It is possible to set up your own payment provider.

Follow the steps below to see how that works:


1)

Create a Voucher and navigate to the "payment settings" -> "make a payment". (It is enabled by default in Vouchers)

Select as payment method: "Custom".


2)

Enter the URL where your payment will take place .

Example: https://www.yourdomain.com/Voucherpay.php


3)

Consumer view:

The consumer opens the Voucher. On the payment page the Voucher user is redirected to your payment URL:


Example:

**Voucher URL: **digivoucher.com/p/abcdef/ab12de34fg56gh89

Note: We pass the unique voucher session ID in the URL. Example: https://www.yourdomain.com/pay.php?voucher=abcfef&voucherid=ab12de34fg56gh89


4)

Develop the payment process on your page.

After a successful payment, set up an API call to inform our platform that Voucher session ID was paid.


API ENDPOINT:

https://www.coupontools.com/en/api-and-webhooks&action=updatesession

You need to pass the operation=CLAIM method. A successful payment is equal to a claimed voucher.

Optional you can pass custom fields (customfield1 untill customfield7) to store additional information (e.g. unique payment reference, payment method, etc)


Note: you can find your API credentials in your account (integrations -> API)


After making the API call you can redirect back to our Voucher URL. example: digivoucher.com/p/abcdef/ab12de34fg56gh89

The consumer will see the voucher was paid and he can save/redeem it now.


5)

Result: the consumer has exact the same flow as our integration payment methods (PayPal/Stripe) but processed through your own payment provider.

The flow to save/redeem/validate the Voucher is exact the same.

Updated on: 31/03/2021

Was this article helpful?

Share your feedback

Cancel

Thank you!