Integration
Casino API integration guide: from sandbox to go-live
This casino API integration guide covers the whole path: credentials, encryption, the wallet callbacks you build, testing and the switch to production.
- sandbox
- encryption
- allowlist
- callbacks
- testing
- go-live
Timeline
How to integrate a casino API, phase by phase
- 01Day 0
Casino sandbox credentials
After the commercial check, you receive the casino sandbox API base URL, keys and the docs pack. The casino API sandbox includes test games and demo players. What that environment is, and is not, is the sandbox definition.
- 02Hours
Casino API setup
Register your callback URL, add our egress IPs to your firewall, and give us yours for the IP allowlist casino API check on our side.
- 0324–72h
Wallet callback integration
Build balance, debit, credit and rollback endpoints. This is most of the work and most of the testing.
- 04Same window
Casino API testing
Run the test suite: duplicates, rollbacks, insufficient funds, timeouts and decryption failures.
- 05After sign-off
Production
Swap stage and prod credentials, enable the agreed studios for each market and launch with monitoring in place.
Security
Decrypting an incoming wallet callback
Wallet callbacks arrive AES-encrypted with the key issued for your environment. A payload that fails to decrypt is rejected before any wallet movement. The exact cipher, IV and key encoding, header names and protocol version for your account are specified in the docs pack.
import crypto from "node:crypto";
// Cipher, IV format and key encoding come from your credentials pack.
const CIPHER = process.env.CALLBACK_CIPHER;
export function readCallback({ payload, iv }, key) {
const decipher = crypto.createDecipheriv(CIPHER, key, Buffer.from(iv, "base64"));
// final() throws on malformed or wrong-key input: never act on that payload.
const body = JSON.parse(
Buffer.concat([
decipher.update(Buffer.from(payload, "base64")),
decipher.final(),
]).toString("utf8")
);
return { ok: true, body };
}Callbacks, webhooks and calls you make
The words callback and webhook are often used interchangeably. In this contract they describe two different outbound messages with different acknowledgement rules; acknowledging one as if it were the other is a defect the sandbox suite should catch before launch.
| Type | Direction | Examples | Must respond? |
|---|---|---|---|
| Calls you make (casino integration API) | You → Turnkeyxgaming | Game list, launch URL, free-round awards | We respond |
| Wallet callbacks | Turnkeyxgaming → you | Balance, debit, credit, rollback | Yes, synchronously, within the timeout |
| Webhooks | Turnkeyxgaming → you | Catalogue changes, studio maintenance notices | Acknowledge only; process asynchronously |
Casino API test environment, demo and stage vs prod
Most teams complete the engineering in 24–72 hours once their sandbox wallet answers callbacks correctly.
The casino API test environment mirrors production: the same endpoints and encryption, with test studios and play money. Use it for the automated suite and for QA on real devices. A casino API demo mode is also available in production for lobby previews. Demo launches do not touch your wallet at all.
Keep stage and prod casino API credentials completely separate: different keys, different callback URLs and different allowlists. The most common production incident is a staging wallet URL left in a production config. A Turnkeyxgaming demo of the sandbox can be arranged through sales before you sign anything.
How long does casino API integration take?
The engineering for a casino API 24-hour integration is realistic when your platform already has a seamless wallet and the team has built one before. A team building its first wallet should plan for the full 72 hours of work, so a casino API 72-hour go-live means engineering complete, tested and ready to switch.
How long does game aggregator integration take from first call to real players? That depends on what sits outside engineering: your licence, studio activation in regulated markets (some studios need their own approval per operator) and your QA cycle. A realistic game aggregator integration timeline lists those steps separately rather than hiding them inside one headline number.
Casino API migration: switching from another aggregator
To switch casino API provider without disrupting players, run both aggregators side by side. Integrate the new wallet callbacks, which are often close to your existing ones, then move studios across market by market while the old contract runs down. Players keep their balances throughout, because the balance lives in your ledger in both cases.
Casino aggregator migration has two traps. Game IDs differ between aggregators, so map favourites and history carefully. And open free-spin awards on the old aggregator need to expire or be honoured before you switch the affected games.
FAQ
Questions operators ask
Is there a casino API SDK?
The API is plain HTTPS and JSON, so any language works. We do not list official SDKs on this site. If you need a casino API SDK for a specific stack, ask what is available for your account.
Can I integrate the casino API with a small team?
Yes. One backend engineer who knows your ledger can integrate the casino API. Most of the effort goes into making the wallet idempotent, not into the calls themselves.
What is the difference between casino game integration and casino games integration?
In practice, nothing. Casino game API integration and casino games integration both mean the catalogue, launch and wallet work described here.
References
Sources and further reading
Primary regulator, standards or studio documentation behind the technical and regulatory points on this page. External links open in a new tab. Links checked 2026-11-15.
- NIST SP 800-38A: Block Cipher Modes of Operation
Standard modes of operation for AES.
csrc.nist.gov/pubs/sp/800/38/a/final
- Malta Gaming Authority
Licensing and player-protection rules for Malta-licensed operators.
www.mga.org.mt
Keep reading
Related pages
- DocumentationAPI docsAuthentication, the game list, demo and real launch, AES-encrypted wallet callbacks and error handling, with test keys to start.Read
- Product · WalletWalletBalance, bet, win and rollback on one seamless wallet: idempotent transaction ids shared by casino games and sportsbook alike.Read
- Guide · ArchitectureHow a casino API worksOne casino round traced end to end: catalogue, launch, wallet callbacks, settlement and the report line the next morning.Read
- PageContactReach Turnkeyxgaming sales on Telegram @turnkeyxhub, WhatsApp or email, and include your licence and target markets for a quote.Read
Get a written quote and sandbox access
Tell us your licence, target markets and products. You get the GGR rate in writing, the studio list for your markets and sandbox credentials.