// the find
heroiclabs/nakama-defold
Nakama Defold Client SDK
Official Lua 5.1 client SDK for Nakama, the open-source game backend from Heroic Labs. Targets Defold specifically but is designed to be portable to any Lua engine by swapping the engine module. Covers the full Nakama feature set: auth, chat, matchmaking, realtime multiplayer, and the Satori liveops layer.
The engine abstraction is genuinely well thought-out — HTTP and WebSocket are behind a thin interface, so porting to Love2D or another Lua runtime means writing one module, not touching the SDK. The coroutine-based sync/async duality is the right call for game scripting; you can write sequential-looking code inside nakama.sync() without blocking the game loop. Retry and cancellation token support is built in at the request level, which is easy to overlook and hard to bolt on later. The codegen pipeline (Go templates against the gRPC/OpenAPI specs) means the API surface stays in sync with the server without manual maintenance.
103 stars for an official SDK from a well-funded company suggests the Defold ecosystem is small and this sees limited real-world stress testing outside Heroic's own QA. The base64-encode-everything requirement for match data is a footgun that will silently corrupt your data if you forget — the README warns you, but the API lets you shoot yourself anyway. Session persistence is tied to Defold's sys.save under the hood, so if you're adapting to another engine you have to reimplement storage yourself with no guidance. Tests require a third-party Telescope fork that supports Lua 5.3+, which is an odd dependency given the SDK targets 5.1 — version mismatch in the test harness can hide real compatibility bugs.