Casino Engine

May 13, 2026 · View on GitHub

Casino Engine

Open-source game aggregator core for iGaming platforms.

The game-mechanics engine powering casinos on 1638.cloud — released under Apache 2.0 so any operator can audit, fork, or drop it into their existing stack.

License: Apache 2.0 Kotlin JVM Built in Malta

Website · Live on moonbet.casino · Live on 2k.ua · Report an issue


What this is

Casino Engine is a production-grade Kotlin microservice that handles the game side of an iGaming platform: provider/aggregator integrations, session orchestration, betting logic, freespin mechanics, and round lifecycle. It runs in production on moonbet.casino and 2k.ua.

It's the only open-source module of the 1638.cloud platform — the other seven engines (PAM, Wallet, Payment, Risk, Engagement, Intelligence, CMS) are proprietary. Operators can use Casino Engine standalone through custom adapters, or run it as part of the full 1638.cloud white-label platform.

Why open-source? Operators deserve to see the code that handles their money flow. Aggregator integrations should be auditable. Game session logic should not be a black box. Every line is on GitHub.


Who this is for

You are...What this gives you
A casino operator running your own platformA production-grade aggregator integration layer you can drop into your stack. No vendor lock-in, no rev share, no licence fees.
A platform engineer evaluating iGaming infrastructureA reference implementation of session, bet, round, and freespin mechanics in Kotlin/Ktor with hexagonal architecture.
A startup thinking about launching a casinoA way to validate the technical model before committing. When you're ready to go live, 1638.cloud handles the licence, payments, KYC, and the rest.

Features

  • Aggregator integrations — Pragmatic Play, OneGameHub, Pateplay, with a documented pattern for adding more
  • Full betting lifecycle — PLACE, SETTLE, ROLLBACK with idempotency guarantees
  • Freespin mechanics — preset retrieval, creation, cancellation
  • Round management — first-bet creation, multi-bet round reuse via external ID, finish lifecycle
  • Event-driven — RabbitMQ publisher for session, spin, round, and game events
  • Hexagonal architecture — clean separation of domain, application, infrastructure
  • gRPC APIgame.v1 protocol with 5 services and published client JAR
  • Pluggable adapters — Wallet, PlayerLimit, File, Currency, Event ports you implement for your stack
  • Production-tested — runs on moonbet.casino and 2k.ua

Quick start

# 1. Clone
git clone https://github.com/nekzabirov/IGaming-Game-Engine.git
cd IGaming-Game-Engine

# 2. Start infrastructure
docker-compose up -d postgres rabbitmq redis minio minio-init

# 3. Configure
cp .env.example .env

# 4. Run
./gradlew run                  # HTTP :8080, gRPC :5050

Full setup, integration guides, and operations docs are in docs/ — see the Documentation section below.


Tech stack

ComponentChoice
LanguageKotlin 2.0.21 on JVM 21
HTTP serverKtor 3.0 (CIO)
RPCgRPC + Protobuf
DatabasePostgreSQL via Exposed ORM
MessagingRabbitMQ
CacheRedis (Lettuce)
Object storageS3-compatible (MinIO local)
DIKoin
BuildGradle (Kotlin DSL)

Architecture: hexagonal (ports & adapters) with CQRS.


Documentation

Technical documentation lives under docs/:

  • Architecture — system design, layers, source structure, event flow
  • Integrations — supported aggregators and how to add a new one
  • Adapters — required adapters (Wallet, PlayerLimit, File, Event, Currency) you implement for production
  • API — gRPC API reference (game.v1 package)
  • Configuration — environment variables and infrastructure
  • Errors — domain exception hierarchy and gRPC status mapping

The bigger picture — 1638.cloud platform

Casino Engine is one of eight engines that make up the 1638.cloud iGaming platform:

#EngineStatus
01Casino Engine — game mechanics, provider integrationsOpen-source (this repo)
02PAM Engine — player accounts, KYC, lifecycleProprietary
03Wallet Engine — multi-currency, real-time balanceProprietary
04Payment Engine — 76+ providers, fiat & cryptoProprietary
05Risk Engine — anti-fraud, AML, behavioural scoringProprietary
06Engagement Engine — bonuses, tournaments, loyaltyProprietary
07Intelligence Engine — segmentation, churn, LTVProprietary
08CMS Engine — content, theming, localisationProprietary

Operators can use the full stack as a white-label or turnkey deployment under our Anjouan master licence, or drop individual engines into their existing platform. Casino Engine works in both modes.

Go-live from contract: 7 days. Setup: from €0 with Founders Circle. See 1638.cloud for full terms.


Want to use this in production?

You have three paths:

1. Run it yourself (free, Apache 2.0). Implement the adapters, host the infrastructure, integrate with your own wallet and player systems. The code is yours. We don't charge, we don't audit, we don't gatekeep.

2. Use Casino Engine on the 1638.cloud platform. Drop into our managed stack — we run the infrastructure, you keep the flexibility. Useful when you want the open-source engine but not the ops burden.

3. Full white-label on 1638.cloud. Casino Engine plus the other seven engines, plus our Anjouan master licence. Live in 7 days. From €0 setup. Contact customer@1638.cloud.


Contributing

Issues, discussions, and pull requests are welcome. Before contributing, please read CONTRIBUTING.md.

We're especially interested in:

  • New aggregator integration adapters
  • Bug reports from production deployments
  • Performance benchmarks and profiling reports
  • Documentation improvements

Security

This is financial infrastructure. If you find a security issue, do not open a public issue — see SECURITY.md for responsible disclosure.


Licence

Apache 2.0 — see LICENSE.

You can use Casino Engine commercially, modify it, distribute it, and run it on any operator platform without paying royalties to 1638.cloud. The only requirements are attribution and not using the 1638.cloud trademarks without permission.


About 1638.cloud

1638.cloud is a B2B iGaming platform built in Malta. We provide white-label and turnkey casino infrastructure under our Anjouan master licence. We open-source the Casino Engine because game mechanics should not be a black box — and because the best way to earn an operator's trust is to let them read the code first.

Founder: Nekbakht Zabirov Email: customer@1638.cloud Web: 1638.cloud

— Built for operators who move first —