Seamless integration


For easier integration, we have prepared for you:

Tool for faster integration (Postman and Insomnia)


For all question you can check here: 20) Seamless interface F.A.Q. 

If you don't get the question, you can write to us in the chat


Functions marked with * are mandatory, other functions are optional


Seamless wallet

Seamless wallet allows players to place bets directly to external system without requiring to transfer funds between accounts.

Communication overview

Communication between servers go through our secure HTTPS RESTful service. The service must be implemented by the external system according to specification.

The Game Engine sends GET requests to the remote system service and expects a JSON response with a status code and the players balance after the transaction

Example:

{"status":"200","balance":"300"}

The status is not the same as HTTP status codes and only 200  (HTTP/1.1 - 200 OK) is accepted and allowed as a response to requests.


Request validation

Each request is escorted with a query param key with a value of a sha1 cached query string and a salt key provided by Xapi Platform

Example:

action=balance&remote_id=123&session_id=123- abc&key=38432ff064690c9b03da519d0c685b1045451c9e).

The query param key value must match sha1([SALT KEY]+[QUERY STRING]

Query string example: action=balance&remote_id=123&session_id=123-abc

Php code quick example
$data = $_GET; 
$key = $data['key']; 
unset($data['key']); 
$hash = sha1($salt.http_build_query($data)); 


Then check if $key == $hash….

Integration

Before we start with wallet integration please provide us with two sets (staging and production) of the following:

  • An IP list for us to whitelist
  • An API endpoint URL where the wallet requests will be made (balance,debit,credit,rollback)

After we whitelist the addresses provided, we will provide you following details:

  • APIi Endpoint url for Xapi calls (Create player, Reporting, etc.) - Please ensure that endpoint is not setup behind CloudFlare
  • API credentials for our incoming calls (Xapi:Create player,reporting, etc.)
  • API credentials for our outgoing calls to your wallet (balance,debit,credit,etc.) (Usualy the same credentials as incoming)

The dev.pantaloo.com domain in this document is not to be confused with the real domain. Please see email with api credentials for real development/production domain name.

External system must provide a secure https url that responds to the following GET requests with a JSON response with a status code and players balance after transaction.

You can use following rest testing form to start with integration:

<html>
	<body>
		<b>development s2s:</b>
		<form action="http://dev.pantaloo.com/api/seamless/provider" method="POST">
	    	u:<input type="text" name="api_login" value="jure_api">
		    p:<input type="text" name="api_password" value="jure">
		    show systems: <input type="checkbox" name="show_systems" value="1" />
			<select name="method">
		    	<option value="giveMoney">giveMoney</option>
		        <option value="takeMoney">takeMoney</option>
				<option value="getPlayerBalance">getPlayerBalance</option>
				<option value="getDailyReport">getDailyReport</option>
				<option value="getDailyBalances">getDailyBalances</option>
			    <option value="playerExists">playerExists</option>
			    <option value="getGame">getGame</option>
			    <option value="getGameDirect">getGameDirect</option>
		    	<option value="getGameList" >getGameList</option>
			    <option value="createPlayer">createPlayer</option>
			    <option value="getPaymentTransactions">getPaymentTransactions</option>
			    <option value="addFreeRounds">addFreeRounds</option>	 
		    	<option value="getSystemUsername">getSystemUsername</option>
			    <option value="setSystemUsername">setSystemUsername</option>
			    <option value="setSystemPassword">setSystemPassword</option>      
			</select>
			amount:<input type="text" name="amount" value="1">
			transid:<input type="text" name="transactionid" value="1397549799">
		    pu:<input type="text" name="user_username" value="juretest">
		    pp:<input type="text" name="user_password" value="jure">
	    	gameid:<input type="text" name="gameid" value="898">
		    playforfun:<input type="checkbox" name="play_for_fun" value="1" title="play for fun?"/>
		    date:<input type="text" name="date" value="2012-01-26"> 
	    	associateid:<input type="text" name="associateid" value=""> 
		    render:<select name="render">
		    	<option value="text">text</option>
    		    <option value="json">json</option>
		    </select>
			date_start
			<input type="text" value="2014-07-29 06:57:36" name="date_start">
			date_end
			<input type="text" value="2014-07-29 06:57:36" name="date_end">
			status:
			<select name="status">
				<option value="PENDING">PENDING</option>
				<option value="PROCESSED">PROCESSED</option>
				<option value="FAILED">FAILED</option>
				<option value="CANCELLED">CANCELLED</option>
				<option value="ERROR">ERROR</option>
				<option value="DENIED">DENIED</option>
				<option value="IN PROGRESS">IN PROGRESS</option>
			</select>
			<br /><br />
			<table>
			    <tr>
					<td valign='top'>
					    <table>
							<caption><i>addFreeRounds params</i></caption>
							<tr>
							    <td>Tittle</td>
							    <td><input type="text" value="freeround 1" name="tittle"></td>
							</tr>
							<tr>
							    <td>Player ids</td>
							    <td><input type="text" value="220650,21352" name="playerids"></td>
							</tr>
							<tr>
							    <td>Game ids</td>
						    	<td><input type="text" value="787,789" name="gameids"></td>
							</tr>
							<tr>
							    <td>Avaliable</td>
							    <td><input type="text" value="2" name="available"></td>
							</tr>
							<tr>
							    <td>Valid from</td>
						    	<td><input type="text" value="" name="validFrom"></td>
							</tr>
							<tr>
							    <td>Valid to</td>
							    <td><input type="text" value="2016-05-11" name="validTo"></td>
							</tr>
				    	</table>
					</td>
					<td valign='top'>
						<table>
							<caption><i>System player operations</i>(getSystemUsername, setSystemUsername, setSystemPassword)</caption>
							<tr>
							    <td>System</td>
							    <td><input type="text" value="hi" name="system"></td>
							</tr>
							<tr>
							    <td>System_Player_Username</td>
							    <td><input type="text" value="thebadmother" name="splayer_username"></td>
							</tr>	
							<tr>
							    <td>System_Player_Password</td>
							    <td><input type="password" value="testpass" name="splayer_password"></td>
							</tr>			
					    </table>
					</td>
				</tr>
			</table>
			<input type="submit">
		</form>
	</body>
</html>




We recommend you start with the simplest call getGameList() in order to get started.

When you think that integration is ready for testing go to Testing tool and Form

If you have any questions regarding seamless wallet integration please take a look at F.A.Q. before contacting support.

Integration process:In depth workflow of a integration