Environments
Environments
Live, and as many Sandbox environments as you need.
Create
An environment is one setup of yours inside Sandbox or Live. It has its own name, server address, settings and data.
In Sandbox, create as many as you need: staging, test, uat-1, uat-2, one per branch. Live has one environment, called live. We create it when you go live.
Create one in the back office, or with these calls (Sandbox only). A person or your build pipeline can use them.
| Call | What it does |
|---|---|
environment.create | Creates an environment. Optionally copies another one. |
environment.update | Changes the server address, page addresses or other settings. |
environment.delete | Deletes an environment. |
environments.list | Every environment of your account, with its settings and its last wallet test run. |
You → us. Sign the call with your API key. See Authentication. These calls carry no Environment header: they act on your environments, not inside one. Each carries requestId and firstSentAt in its body.
Settings of an environment
| Setting | What it is |
|---|---|
| Name | Lowercase letters, digits and -. Unique in your account. |
| Server address | Where we send wallet calls and events. You can change it at any time. After a change, every call, including retries already waiting, goes to the new address. It must be https. We refuse addresses on private or local networks and do not follow redirects. |
| Page addresses | The web pages that may show our game and send client messages. |
| One session per player, or several | Your choice. Several is the default. |
| Each game on or off | Set in the back office. |
| Each game’s parameters | Set in the back office. |
| Coin code and decimals | For social casinos. Social coins are not an ISO currency, so both sides must agree what 100 means. Example: COIN, 0 decimals. |
The new address must reach the same wallet: the same balances and the same transactionIds. For a new wallet, create a new environment. A refund sent to a wallet that never saw the stake would be lost.
Each environment sees only its own sessions, rounds, wallet calls and events. The same playerId in two environments is two different players.
Create is limited to 100 an hour per account.
Request
{
"requestId": "rq-77121",
"firstSentAt": "2026-10-31T09:10:00Z",
"name": "feature-lobby",
"copyFrom": "staging",
"serverUrl": "https://staging.casino.example"
}
Answer
{
"ok": true,
"result": { "environmentId": "…" }
}Copy
A new environment can copy every setting from another one. A branch then starts with the same setup as staging.
In environment.create, set copyFrom to the name of the environment to copy.
Branches
- 1
Your build pipeline calls environment.create.
With copyFrom: "staging" and the branch’s server address.
- 2
It runs its tests against that environment.
Every call names the environment in the Environment header.
- 3
It calls environment.delete.
Open sessions close, open Mines rounds finish, and waiting calls are still sent.
- A name already used gets
invalid_request: “name is already used.” - A pipeline API key that may not manage environments gets
not_allowed. - If the branch’s server is not up yet, calls in that environment fail. Other environments are not touched.
- Give the pipeline an API key that is allowed on “all Sandbox environments”. Then it reaches new environments without a person adding each one.
Delete
environment.delete does this:
- It stops new sessions and rounds at once.
- Open sessions close as
environment_deleted. - Open Mines rounds finish at once, as if their time ran out.
- Waiting wins, losses and refunds are still sent until you accept them.
- Waiting events are still sent.
- The data is removed 30 days after the last of them was accepted.