Deposit
This poker software supports real money gateways like PayPal, Paysafe, etc. You can also integrate any crypto payment gateways like nowpayments.io, coinpayments.net, coingate.com, etc.
Making a deposit can be possible with just a few clicks. From the cashier section, under the deposit tab, a player can choose the available payment option to make his first deposit. Depending on the client's choice and business process it can be manual fiat or crypto too.
To make a deposit, a player must follow these steps:
-After login go to the Cashier.
-Select the deposit tab and select your preferred payment option.
-Enter the amount you want to deposit.
-Click on the Deposit button to confirm the process.
Based on the gateway response and opted payment method a confirmation will be sent to your email. Check your chip balance as it will auto-process.
Gateway Integration Guide - General Process
This guide will give you a high-level approach to the general integration process. Here, you will get every single necessary step that is required for a gateway instruction. There are lots of gateways in the market, so it's not possible to cover each and every one. We hope this general approach will help you.
Merchant ID The first step is to signup for your payment gateway. From the gateway dashboard, you have to collect merchant identification parameters according to their internal setup. It can be a Client ID, Client Secret Key, API Key, etc.
OAuth Almost, each payment gateway uses REST API for communication using HTTPS requests. The OAuth protocol handles different types of authorized access for each API functions via access tokens. Merchant IDs are required to generate the tokens.
Token Before creating any payment it is required to generate the token. For each API request, there must be a token that will work along with the API function which resides in the request header.
Generally, it is very easy to get tokens by making an API call to /api/oauth2/token
URL. For each token we suggest creating a token with two scopes of authorizations;
-The first is for payment-create and only use for creating new payments.
-Second will be for payment-all that handle other payment operations.
It is necessary to create a fresh new token for any expired token.
Creating the Payment
To create a payment you have to make Gateway's REST API call to /api/payments/payment
URL. During the payment creation process, it is required to specify all the required parameters; amount, currency, accepted payment methods, default payment method, order method, gateway language, notification address (notification_url
), and return address (return_url
).
In response, your gateway returns the JSON object with all details about the payment. The primary and most important parameter is id
which is a unique identification number to recognize a payment within the gateway system. Save this information in your poker software database.
Another important parameter is the gateway_url
which is core parameter to initiate the gateway process.
Initiate your Payment Gateway
As explained in the "Introduction" you can initiate the payment using both methods by using either the 'Redirect' or the 'Inline' method. Check your gateway to which option they have and follow with that.
Further for initializing the payment gateway you can choose any one method from a javascript initializing or a pre-created payment. We suggest you use "Javascript initializing" which can follow a one-click payment. If you plan to with multi-step payment by collecting other information then, follow the "pre-created payment".
Javascript Initializing
This method also knows as Javascript calling. After getting the payment request confirmation, the game server receives an order ajax request. Meanwhile, an access token is also get generated in order to create the payment. In response, a gateway_url
is created to initialize the payment gateway with javascript.
JavaScript
gatewaty.checkout({gatewayUrl: url, inline: true});
Here in this code sample, the method is parameterized with gatewayUrl
as an object of the created payment, and the inline parameter defines the option to initialize the payment gateway.
In order to follow gateway.checkout
you must include the Gateway Javascript API like this;
<script type="text/javascript" src="https://gatewayUrl/pay/js/embed.js">
Here is an example of code that is using javascript to initialize the payment gateway.
Return update from Payment Gateway
For a payer, each payment activity either payment success or canceled must have a return back status along with a notification. There are two methods that are mostly used by payment gateway companies.
Return URL
It's already explained, that for each created payment we have a returl_url. As the payment is created, the return_url
parameter must be passed in the callback object. Once the payment gets finished, the player returns to the return_url
and you can use the GET method to retrieve the id
which works as player identification. A payment status call function must be applied to show the current payment status.
Callback Function
In case, if your payment gateway does not support the required URL redirection you can find a callback function together with gateway.checkout
function while initializing the payment gateway.
The sample code looks like this;
gateway.checkout({gatewayUrl: inlineCreateResult.url, inline: true}, function(checkoutResult) { alert(checkoutResult);})
Just after the payment is made, this defined callback function will be executed. We recommend following an ajax request to the game server which updates the payment status to display the payer.
Payment Status Notifications
Notifications help payers to get updates about the payment status which comes from the game server during the payment cycle.
As explained, during creating the payment, a notification address (notification_url
) is passed in the callback object. This URL received an HTTP/GET notification as the payment status is updated. The id
parameter will map a particular order and you can make a payment status call to define the recent payment status. It is recommended to save the status in the game server database and perform other activities if required.
Profile API - Pokerscript
The profile API provides all the required parameters that are required for any payment gateway.
POST URL
"https://example.com/profile/?addchips=add"
For security reasons, it is mandatory to use HTTPS for each request.
Request Body Here is a sample JSON representation of users' profile requests.
In case you have any problem with your gateway integration, talk to the support team. Personalized one-to-one guidance will be provided by the assigned support developer.
Last updated
Was this helpful?