Test tooling
Simulate end-of-period behaviour while integrating (reopen windows, inject scores, manage bots and lobbies, force rollovers), all scoped to your test environment.
When you wire Kraty into your game you need to exercise behaviour that normally only happens on a schedule: a window ending, a weekly board rolling over, bots filling a lobby, rewards and webhooks firing. Waiting for the real clock is no way to test. The Test tooling lets you trigger those paths on demand.
Everything here acts on your test environment only. Test and live run on separate windows, leaderboards, and lobbies, so a force-end or rollover can never touch a real, live event. A test player never appears on a live board.
Two ways to drive it
| Where | Who / what authenticates | Best for | |
|---|---|---|---|
| Test tabs | A Test tab on each event and each leaderboard in the portal | A logged-in member with dev_tools.trigger (GAME_ADMIN, GAME_DESIGNER, or GAME_DEVELOPER) | Clicking through behaviour by hand while building |
| Dev endpoints | POST /server/v1/dev/* | A test server_integration API key | Scripting the same triggers from CI or an integration test |
Both hit the same underlying engine; they differ only in who's allowed to fire them and how.
The event Test tab
Open an event and switch to Test. Actions resolve the event's current test window:
- End the window now: finalize the active test window exactly as the
scheduler would at
endsAt: settle leaderboards, expire in-progress attempts, dispatch window-end rewards and webhooks, close lobbies. - Reopen the window: re-activate an ended test window so you can keep playing. Its leaderboards are un-finalized (entries cleared back to live) and lobbies reopened. Lets you replay an end-of-window without recreating the event.
- Inject test players: add N synthetic ranked players to the active test board, so you can see a populated leaderboard immediately.
- Bots: draw bots onto the test board. Pick a bot type to use a specific bot, or leave it on Event's bot bindings to draw from what the event is configured with. Remove bots clears them again.
- Clear the board: wipe the active test window's leaderboard.
- Open test lobbies: each forming/active test lobby is listed with:
- Fill (forming only): promote the lobby now and top up empty seats with bots, the same path matchmaking takes on a fill-by timeout.
- Close: close the lobby.
The leaderboard Test tab
Open a leaderboard and switch to Test:
- Roll over the period now: snapshot the current period, pay per-place / per-progression-tier rewards, apply promotion & relegation, and open a fresh period. A no-op on an all-time board.
- Inject test players: seed synthetic ranked players. On a segmented board you pass the tier / segment value to seed.
- Clear the test board: wipe every test ranking across all segments.
Dev endpoints (for automated tests)
For CI and integration tests, the same force-end and force-rollover live
on the server API, driven by a test server_integration key:
POST /server/v1/dev/events/{eventKey}/end-now
POST /server/v1/dev/leaderboards/{leaderboardKey}/rollover-nowBoth resolve the event / board by its stable key within the calling key's game, and act on that key's environment.
These reject a live key with 403 forbidden; dev triggers require a
test-environment API key. There is no way to force-end a live event or
roll a live period through them. They are also off-limits to the
client SDK key; only a backend server_integration key may call them.
To wipe accumulated test data and start from a clean slate, use Reset test data in Game settings.