Guide · Testing
Test play must not reach the invoice
Sandbox rounds are there so engineers can break the wallet safely. If those rounds land in the production GGR file, you will either invoice fiction or spend a week explaining a negative Tuesday.
7 min readUpdated By the Turnkeyxgaming team
Separate by environment, not by a player's good intentions
Production credentials and sandbox credentials should be different secrets, and the wallet should know which one called it. A flag on the player account ('this is a test user') fails the day someone copies a production player into a test. Environment is the reliable boundary. Staff accounts that must exist in production, for screenshots or VIP checks, need an explicit exclusion list in the revenue job, reviewed when people join and leave.
Currencies used only for tests, and rounds tagged by the sandbox key, stay in a test report. The invoice uses the production report. When the two disagree with the studio, you compare production to the studio, not the sum of both environments. Mixing them makes every reconciliation look like a leak.
Give the revenue job an environment column it cannot ignore. A round encrypted with the sandbox key is test activity even if the player id also exists in production, which happens the moment someone copies a row to reproduce a bug. Staff accounts that must play on the live host are the exception you name, not a vibe you hope the export will notice. When someone joins or leaves, the exclusion list changes in the same week, or their Monday test sits inside a closed day.
Which activity is allowed to become an invoice line
Split the streams before anyone totals them. A reconciliation that starts from a blended file cannot tell a wallet bug from a test session.
| Source | Where the rounds go | What finance is allowed to do with them |
|---|---|---|
| Production key, real player | Billable daily file. | Include in the figure you compare with the studio. |
| Sandbox key, any player id | Test activity file only. | Never fold into the billable total, even as zeroes. |
| Production key, named staff account | A separate exclusion the revenue job applies. | Keep the rounds for audit. Keep them out of the invoice. |
| A production player copied into a test database | Still test, because the key that encrypted the call is sandbox. | Do not 'rescue' the rows because the player id looks familiar. |
A clean split
- 01
Two keys
Refuse sandbox keys on the production wallet host.
- 02
Staff list
Exclude named staff accounts in production, and review the list monthly.
- 03
Two files
Write a test activity file and a billable file. Invoice only the second.
Compare like with like when the studio total disagrees
Send the production file, not the sum of production and sandbox. Adding the test file to 'explain the gap' invents a second gap the studio cannot see, because their invoice never contained those rounds.
A €12,400 jackpot that nobody won
On 30 April at 11:20 a QA engineer triggered a jackpot scenario in staging to test the large-win review queue. Staging had been seeded from a production snapshot weeks earlier, so the player id, the brand and the game record all looked real. The round settled with a €12,400 win, the wallet credited it, and the reporting job picked it up because staging and reporting shared a rounds table with no environment column. The billable file for April carried the prize.
The studio's invoice did not, because its sandbox account is a separate tenant and its report never held the round. One line made the April reconciliation impossible: our file showed €12,400 of wins the studio had never heard of. The engineer found it by sorting the gap by amount, which is the fastest route when a difference is one row rather than a pattern.
The fix was not a tighter filter. It was an environment column written on the round at creation from the credential that encrypted the call, and a reporting job that reads only production. The test file still exists and earns its keep: a monthly count of sandbox rounds carrying production player ids is a decent measure of how carelessly snapshots are reused. The demo mode rules guide covers the player-facing version of the same boundary.
The evidence an invoice needs behind it
| Artefact | What it proves | Where it should live |
|---|---|---|
| Credential id on every callback | Which environment created the round, whatever the player record says | On the round row, written at creation |
| Version of the revenue query | Which logic produced the file that was invoiced | Beside the archived file, not in a repository branch |
| Staff exclusion list and review date | Why a named account's rounds are absent from the total | With the file for that month |
| Test currency list | That a currency in the report is not a test artefact | In the reporting configuration, versioned |
| Hash of the file as sent | That finance's copy is the one that was archived | In the archive record |
FAQ
Questions operators ask
Can we demo a game to a prospect from production?
Use a staff account that the revenue job excludes, or use demo mode where the studio allows it. Do not use a normal player funded with real balance.
Can a sandbox wallet share its database with production if we filter in the query?
That filter is the incident. A missed predicate, a report someone exported from the primary, or a replica that lagged past the cut-off will put test stake in the billable file. Separate secrets are the boundary. A WHERE clause is a courtesy on top.
How should a screenshot session for a commercial pitch be funded?
On a named staff account the revenue job already excludes, or in demo where that title allows it. Funding a normal production player so the balance looks realistic puts the session on the invoice.
Should sandbox rounds be purged after testing?
No. Keep them, separated, because a disputed test result is easier to answer with the round than with a memory of it. What must not happen is a report reading them by accident. Retention is a question for your own policy, but deletion is rarely the control that was missing.
Do rounds from a client demo count towards GGR?
If they ran on a production credential with real balance they will appear in the production file, and the studio will bill for them. Use demo mode where the title allows it, or a staff account the revenue job excludes. Decide which before the demo, because afterwards you are choosing who explains the line to finance.
Keep reading
Related pages
- IntegrationIntegrationSandbox keys, AES-encrypted wallet callbacks and the four wallet endpoints, then a 24–72 hour go-live once decryption and retries pass.Read
- Guide · LobbyDemo modeHow demo play works where a studio allows it, why some titles have no demo at all, and how demo stake stays out of the GGR file entirely.Read
- Guide · FinanceGGR explainedCasino GGR is stakes minus wins. It is not NGR, and sportsbook GGR can swing on a single result, so the definition matters.Read
- DocumentationAPI docsAuthentication, the game list, demo and real launch, AES-encrypted wallet callbacks and error handling, with test keys to start.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.