Getting started
Overview
What an integration consists of, what we exchange before the first launch, and how a game is launched for real money and as a demo.
What you integrate#
| Part | Direction | Where |
|---|---|---|
| Launch URL, real and demo | you build it, the player's browser opens it | {launch-url}/{game}, {demo-url}/{game}, {demo-url}/{operator}/{game} |
Wallet methods: auth, info, withdraw, deposit, rollback, playerNotificationCallback | we call you | {wallet-url}/<method> |
| Free bets: information, add, cancel | you call us | {api-url}/v4/freebets… |
| Round details | you open a page | {round-details-url} |
Iframe messages (ifc.*) | game ↔ your page | postMessage |
| Request signature, integer amounts | both directions | Securing requests, Amounts |
What you send us#
Before your first launch we set up your operator with these details. You can change them later through your account manager or your back-office access.
| Item | What it is for |
|---|---|
| Brands | Each brand is a skin of the games with its own look, limits and currencies. Name your default brand: a launch without brand opens it. |
| Allowed origins of each brand | The origins (scheme, host and port) of every page that embeds the games, e.g. https://casino.example. They are the only pages that may frame the game and the only ones it exchanges messages with. return_url and account_history_url must be on one of them. |
| Wallet URL | The base URL of your wallet methods, {wallet-url}. We call {wallet-url}/auth, /info, /withdraw, /deposit, /rollback and /playerNotificationCallback. |
| Currencies | Which of our currencies each brand offers. We set bet limits per currency. |
| IP addresses (optional) | The addresses you call our free-bet methods from, if you want your key limited to them. |
| Public demo (optional) | Which brands may open a demo by URL without a token. |
| Zero-amount deposits (optional) | Off by default: we send no deposit for a lost round. Ask us to switch it on if your wallet expects one. |
What we give you#
| Value | Use |
|---|---|
| Client id and client secret | One key for both directions: we sign every call to your wallet with it, and you sign every call to us with it. The id looks like acme-client-0123456789ab; the secret is shown once. See Securing requests. |
{launch-url} | The base of real launch URLs: …/{game}?…. |
{demo-url} | The base of demo launch URLs. |
{demo-url}/{operator} | Your own demo base, with your operator code in the path: demo URLs …/{game}?currency=…&lang=…&return_url=… built on it open in your brands. |
{api-url} | The base of the free-bet methods you call. It may include a path. |
{round-details-url} | The round-details page. |
| Provider key | The value of provider in our calls and answers. See Specifications. |
| Your operator code and brand codes | For operator and brand. |
Launching a real game#
You build the URL yourself; no server call comes first. Open it in an iframe on your page (or as a whole page). The game then opens a session with us, and we check the token with your auth method before the player sees a balance.
{launch-url}/{game}?user={user}&token={token}¤cy={currency}&operator={operator}
&lang={lang}&return_url={return_url}&account_history_url={account_history_url}
&irc_duration={irc_duration}&irc_elapsed={irc_elapsed}&brand={brand}| Field | Type | Presence | Meaning |
|---|---|---|---|
user | string (1–128 chars) | required | Your player reference, 1–128 characters, with no control character (U+0000–U+001F, TAB included, U+007F, U+0080–U+009F) and no unpaired surrogate. It must not start with demo:; a value that breaks a rule gets the error page (400). We send it back as user_id in every wallet call. |
token | string (1–512 chars) | required | A one-time token you create for this launch, 1–512 characters. We pass it to your auth method as user_token and never store it; a second launch with the same token is refused. |
currency | string | required | The session currency, 2–10 letters, any case (we upper-case it). Must be one of our currencies and enabled for the brand. |
operator | string | required | Your operator code, as on your hand-over sheet. |
lang | string | optional | Interface language, any case (en, EN, pt-br). A value we do not ship falls back to the brand default; it is never an error. See Languages. |
return_url | string | optional | Where the "Back to lobby" entry leads. An absolute https: URL of at most 2,048 characters, without user name or password, on one of the brand's allowed origins. |
account_history_url | string | optional | Opens from the "Account history" entry of the game's menu and from the reality-check window, in a new tab. Same rules as return_url. |
irc_duration | string | optional | Reality-check period in seconds, an integer 60–86,400. Turns on the game's own reality-check timer: see Reality check. Any other value, for example 30, refuses the launch. |
irc_elapsed | string | optional | Seconds the player has already played in this period, an integer 0–2,147,483,647. Ignored without irc_duration; with it, any other value refuses the launch. |
brand | string | optional | Optional: which of your brands to open, when you have more than one. A brand other than your default brand is accepted only if your auth answer confirms it in data.brand. |
The path holds the game: one of the game identifiers.
An example, with the URLs percent-encoded as every query value must be:
{launch-url}/dice?user=u_829301&token=b1c4e0f2-launch-7731¤cy=USD&operator=acme&lang=en&return_url=https%3A%2F%2Fcasino.example%2Flobby&irc_duration=3600&irc_elapsed=0- Parameters we do not know are ignored, so you may add your own (for tracking, say).
- A parameter we know that is present but invalid refuses the launch. The refusal names the parameter, never its value:
irc_duration is not valid, orreturn_url is not on an allowed origin of the brand. The game shows the refusal on its own screen and posts nothing to your page; the message is in our answer to the game, which your developer sees in the network panel of the browser. A bad link should be found while you integrate, not dropped in silence. - The token is used once. If
authfails or times out, we have not used the token up on our side; whether it can be retried is your wallet's decision. - The player's platform (
mobileordesktop) is taken from the browser of the launch and sent in our calls.
Launching a demo#
A demo plays with play money from our demo wallet. It needs no token and makes no call to your wallet; its rounds are marked as demo rounds.
{demo-url}/{game}?currency={currency}&lang={lang}&return_url={return_url}&operator={operator}&brand={brand}| Field | Type | Presence | Meaning |
|---|---|---|---|
currency | string | optional | Optional, default USD. Same format as for a real launch. |
lang | string | optional | As for a real launch. |
return_url | string | optional | As for a real launch. |
operator | string | optional | Optional: run the demo in one of your brands; or put your operator code in the path instead (below). Without an operator the demo opens in our own demo brand: only our own pages may frame it, so your page cannot embed it, and a return_url on your site refuses the launch. |
brand | string | optional | Optional, with operator: which of your brands. Only brands with "Public demo by URL" switched on open a demo. |
{demo-url}/crash?currency=EUR&operator=acmeYour operator in the path#
The same demo, with your operator code moved from the query into the path. {demo-url}/{operator} is then your demo base: a demo URL of the form {base}/{game}?currency=…&lang=…&return_url=… works with that base and nothing else changed. It is the same request with the same rules as operator=: the brand needs "Public demo by URL", the page that frames it must be on one of the brand's allowed origins, and so must return_url. If the query also has operator, it must be the same code.
{demo-url}/{operator}/{game}?currency={currency}&lang={lang}&return_url={return_url}&brand={brand}{demo-url}/acme/crash?currency=EUR&lang=enEmbedding the game#
<iframe src="{launch-url}/dice?user=…&token=…¤cy=…&operator=…"
allow="autoplay; fullscreen; clipboard-write"></iframe>- The page that frames the game must be on an allowed origin of the brand. Without allowed origins the game opens only as a whole page.
- If you sandbox the iframe, allow
allow-popupstoo: the account-history link opens a new tab. - The game posts its messages only to an allowed parent origin, never to
"*". Opened as a whole page it posts nothing.
When a launch is refused#
A refused launch is shown by the game's own screen, with no message to your page: the player sees one short message; the cause is in our logs and, for a parameter, in our answer to the game.
| Situation | Code (HTTP status) | The player sees |
|---|---|---|
| Unknown game, a required parameter missing or malformed, unknown operator, operator without a wallet endpoint, brand not found, or a demo of a brand without public demo | our error page (404, or 400 for a malformed parameter) | "This game link is not valid. Go back and open the game again." |
A brand other than your default brand that your auth answer did not confirm, or an auth answer naming another brand | NOT_FOUND (404) | "The game could not be loaded. Please reopen it from the lobby." |
A known parameter present but invalid (for example irc_duration out of range, or return_url on an origin that is not allowed) | INVALID_REQUEST (400) | "The game could not be loaded. Please reopen it from the lobby." |
| The game is disabled, the brand or operator is suspended, or no configuration is in effect | GAME_DISABLED (403) | "This game is not available right now." |
| The currency is not enabled for the brand or has no limits | CURRENCY_NOT_ALLOWED (422) | "This currency is not available for this game." |
Your auth answered 401, or answered 200 with another user_id | INVALID_SESSION (401) | "Your session has ended. Please reopen the game from the lobby." |
Your auth answered 403 | TOKEN_EXPIRED (401) | "Your session has expired. Please reopen the game from the lobby." |
| The launch token was already used with us | LAUNCH_TOKEN_USED (401) | "This game link was already used. Please reopen the game from the lobby." |
Your auth failed any other way: 413, 500 or another code, a timeout, an HTTP 5xx, a malformed answer, or a currency other than the launch currency | WALLET_UNAVAILABLE (503) | "The wallet is not responding. Nothing was charged; please try again." |
| The player is blocked in our back office | PLAYER_BLOCKED (403) | "Your account cannot play right now." |
Too many launches from one address, or too many auth calls for your operator in a minute | RATE_LIMITED (429) | "Too many bets at once. Please slow down." |
The error page#
A link our servers reject before the game starts gets a small static page in neutral colours with one sentence: "This game link is not valid. Go back and open the game again." (status 404 or 400), or "The game is not available right now. Try again in a moment." (status 503). It names no cause.