Result codes
Return the code as both the HTTP status and the code field, with a short message. Refusals' messages are shown to the player.
| Code | Meaning | What the game does |
|---|---|---|
200 | OK | Accepted. For money calls: moved, or already moved by the same request earlier. |
400 | Bad request | Refused; nothing moved. The message is shown to the player. |
401 | Invalid signature, unknown client, or invalid/expired token | Refused. On /auth the player is asked to reopen the game. |
402 | Insufficient funds | Bet refused; the player sees your message. |
403 | Account blocked or not allowed | Refused; the player sees your message. |
404 | Unknown player | Refused. |
5xx | Server error | Unclear: money may have moved. Withdraws are held for reconciliation; deposits are retried. |