Wire the backend in one import
Triggair is a full game backend for browser games — identity, cloud saves, leaderboards, an economy, LiveOps, competition, moderation & compliance, analytics and more, behind one import and one publishable key. Errors tell an agent how to fix the call, and a one-command self-test closes the loop.
1 · Install & initialize
npm i @triggair/sdk
import { createClient } from '@triggair/sdk';
const tg = createClient({ key: 'tg_pk_your_key' });
Only the publishable key (tg_pk_) is needed. NEVER put a secret key (tg_sk_) in client code — it belongs on a server. 2 · Identify the player
const { playerId } = await tg.login();
An anonymous player token is minted from a device id on first use and silently refreshed. Every player-scoped call attaches it automatically — no accounts, no login screen required. 3 · Verify the integration
After wiring the SDK, run the MCP tool triggair_verify_integration (or the dashboard's verify runner). It live-probes player + saves + leaderboards and advises on CORS, with pass/fail per service and fix hints — closing the loop. That's the whole loop. Read the guides to learn how each system works, grab a snippet from the full recipes for saves, leaderboards, economy, social, moderation, compliance and more, keep the API reference handy, and check the error reference when something throws. Building with an agent? Point it at llms.txt or paste the Drop-In prompt.