General connection information

Terms:

  • Platform - a set of software tools that provides a Partner with access to games through the API described in this documentation.
  • Partner - an external platform that connect to the Platform. It can be represented by a game aggregator or a standalone website that integrates directly.
  • Control Panel - Additional information on connecting to the Platform is available in the Control Panel, as well as other settings that can be configured by a Partner. A set of functions is negotiated for each specific Partner individually. Access to the Control Panel is carried out using the Partner ID and password issued upon connection. The password can be changed by contacting technical support.
  • Partner ID - alphanumeric sequence of characters. Only lowercase Latin letters can be used as characters. ([a-z][a-z0-9]{2,12})
  • Secret Key - used to sign requests from the Platform to a Partner. This key is set in the Partner's Control Panel.
  • Signature - MD5 hash obtained from the request parameters and the Secret Key. Signature is used by a Partnerto verify the validity of requests from the Platform to a Partner
  • Player - a user who launched a game.

Denomination:

  • Denominator - the price of the game coin relative to the player's currency
  • In the system, the denominator is indicated in hundredths. So for a coin price equal to one unit of the player's currency, the denomination value should be 1.00, which is 100 in hundredths.
  • Examples of available denominations (the list can be configured individually for a Partner).
    • 1 = 0.01
    • 5 = 0.05
    • 10 = 0.1
    • 25 = 0.25
    • 50 = 0.5
    • 100 = 1
    • 500 = 5
    • 1000 = 10
    • 2000 = 20

Integration example (php):

Connecting a Partner to the Platform.

Preliminary steps:

  1. Each Partner is assigned a Partner ID, which is negotiated before connecting to the Platform.
  2. Each Partner receives a password that is used to access the Control Panel along with Partner ID.
  3. Secret Key can be set and changed by a Partner an the Control Panel at any time independently.

Practical connection steps:

  • Create a custom designed web page containing an iframe for loading an integrated game - Example
  • Use the Platform API to get a list of games, currencies, as well as to start a game session
  • Implement the work of methods on a Partner's side in accordance with the Partner's API
  • An example implementation of integration for PHP.

How to work with the API (Workflow):

  1. Make a request to the Platform to initialize a session
    For a REAL session /init.session, the passed parameters are:
    • currency: string - Game session currency
    • game.id: number - Game ID on the Platform side
    • partner.alias: string - Partner ID (Login of Subagent)
    • partner.session: string - Player session ID generated by a Partner
    For a REAL session with FREEROUNDS /init.session, the passed parameters are:
    • currency: string - Game session currency
    • freerounds.id: string - Freerounds ID
    • game.id: number - Game ID on the Platform side
    • partner.alias: string - Partner ID (Login of Subagent)
    • partner.session: string - Player session ID generated by a Partner
    For a DEMO session /init.demo.session, the passed parameters are:
    • currency: string - Game session currency
    • game.id: number - Game ID on the Platform side
    • balance: number - Balance in cents (hundredths)
    • denomination: number - (Optional) Game session Denominator in hundredths. If not specified, the default value is 100
  2. Get configuration
    for a REAL session
    • While processing a request to initialize a session, the Platform sends 2 requests to a Partner: /check.session and /check.balance to check that the request has been initialized by a Partner, as well as to receive a session parameters.
    • If the request check is successful, the Platform sends a configuration to a partner to launch a game
    for a REAL session with FREEROUNDS
    • During the processing of the session initialization request, the Platform sends 3 requests to a Partner: /check.session, /freerounds.activate and /check.balance to check that the request has been initialized by a Partner, as well as to receive a session parameters.
    • If the request check is successful, the Platform sends a configuration to a partner to launch a game
    • When activating freerounds, remember the following features:
      • If an error occurs with any of the 3 above requests, then the Platform will consider the freerounds as NOT activated. Including if a request to /freerounds.activate was successful.
      • A player cannot activate freerounds for a game in which freerounds are already activated.
      • If a game has an unfinished turn, an unfinished feature and/or active free spins (not freerounds), all these features will be forcibly completed, and the winnings for them will be sent with the /deposit.win request immediately after the /check.balance request.
      • Freerounds are always activated with a maximum number of lines and a minimum bet to play. More about freerounds and how to manage a amount of winnings on them
    for DEMO session
    • The Platform sends a configuration to a Partner immediately to launch a game without any requests
    • Features of the demo sessions:
      • Points 4 and 5 of the "How to work with the API (Workflow)" do not apply to demo sessions
      • Demo sessions send absolutely no requests to a Partner during its work
      • It is impossible to top up demo session balance
      • It is impossible to track a status (for example, balance, number of turns, winnings, etc.) of a demo session
      • It is not possible to activate freerounds for demo sessions
      • Demo sessions do not need to be closed with /close.session
  3. Launching a game by Partner using the configuration received from the Platform. The mechanism for obtaining a link for an iframe from the Parameters is described in detail in the section Launching an integrated game
  4. Processing of the game turns by the Platform. The Platform generates 2 requests to a Partner for each turn of a Player
    • /withdraw.bet - withdrawal of a bet from a player's balance. Withdrawal occurs before the visualization of a result
    • /deposit.win - enrollment of winnings per turn to a balance. This request is sent even if the payoff is zero. This request is sent after a final calculation of the winnings for a game turn.
      So, for example, if a game has bonuses, free spins and/or a double feature, then a final calculation of the winnings occurs after completion of these features.
    As a result of each of these requests a Partner sends a session balance on its side, and the Platform checks it with its own data. Thus, the balance matching mechanism is guaranteed both on the Platform side and on the Partner side at any time.
  5. Error handling by the Platform. All error handling operations make several connection attempts and, in the absence of a correct response from a Partner, require a manual start to complete a turn.
    • /trx.cancel - notification about error while withdrawal from a balance and canceling this transaction
    • /trx.complete - notification about error while enrollment the winnings to a player.

Launching an integrated game:

  • Getting a configuration to launch:
    1. Run a game session initialization request (/session.demo.init - for a demo session /session.init - for a real session)
    2. In the body of the response to the request, the "response" parameter will contain a JSON object of the following form
      {
        "casinoBrand": "some",
        "clientDist" : "https://example.com",
        "token" : "85520955afda57b28905181593440dbb",
        "targetElement": "game"
      }
    3. To get a URL to launch a game, you need to combine the parameter values in the following way: {clientDist}?t={token}
      The result will be a link like this
    4. https://example.com?t=85520955afda57b28905181593440dbb
    5. Set the resulting link to a src attribute of a target iframe
    6. <iframe src="https://example.com?t=85520955afda57b28905181593440dbb"></iframe>