Ontwikkelaarsportaal

Ontwikkelaarsportaal / Handleiding voor operators

Technische documentatie in het Engels

OPERATOR GUIDE

Go-live checklist

  • Signature verification passes all vectors in docs/signature-test-vectors.json.
  • bet with insufficient balance returns INSUFFICIENT_FUNDS and debits nothing.
  • The same win sent three times credits once and returns the same balance each time.
  • rollback of a known bet refunds it once; sent again, it changes nothing.
  • rollback of an unknown bet returns TRANSACTION_NOT_FOUND, and that bet is refused if it arrives afterwards.
  • win and rollback succeed for a player whose session has ended.
  • Wallet endpoints answer in under 500 ms at your peak load.
  • Your site origins are registered with us, and the game loads in your frame on desktop and mobile.
  • Your daily totals match reports/daily for a test day.
  • If you use free rounds: a free-round win (no bet, reference_transaction_id: null) is credited once, and your bonus system issues awards with a stable reference.
  • A kind: "jackpot" win with no bet reference is credited once, including when retried after round closure.
  • If you chose Ed25519: your wallet verifies the published test vectors, fetches our key document, and refuses a call signed by any other key.
  • Your wallet refuses a correctly signed call whose body operator_id is not your operator id, and moves no money (section 1.2; HMAC and Ed25519). Required for go-live.
  • Your wallet ignores fields it does not know.
  • A bet with another player's (or a made-up) session token is refused with TOKEN_INVALID.
  • A reused transaction id with other details is refused with TRANSACTION_MISMATCH; a rollback after the round's win with ROUND_ALREADY_SETTLED.

Going live

  1. In the partner portal, open Go-live. It shows the checklist: your production wallet URL set (not the hosted reference wallet), a passing conformance run against exactly that URL and signing mode in the last 30 days, your site origins, the commercial terms, and a portal admin. The run must include a passing signature.operator check (section 1.2); a run recorded before that check existed does not count, and the platform enforces this (not only the portal).
  2. A developer or admin runs the conformance test there: give a test player of yours with at least 10 units of balance, the currency and a live session token of yours for that player. We send the same signed calls as the CLI below (about 45, under a minute or two), with our real signature: HMAC with your wallet secret, or Ed25519 with our active published key. The report lists every check, and for each failure what we saw and how to fix it. Runs are kept as a record and cannot be edited; at most 12 per hour, one at a time.
  3. When every blocking item is done, your portal admin presses Ask to go live. A SPILVON staff member reviews it and approves; it can never be the person who asked. On approval the checklist is checked again (a wallet URL changed in between stops it), and the account becomes real money at once: wallet calls no longer carry sandbox, billing starts under your agreement (a prepaid account waits for its first top-up), and the normal API limit applies. From then on, changes to the wallet URL, origins, IPs and signing are requests that SPILVON approves.

Your operator id and secrets stay the same. If they were ever in a shared or test environment, rotate them from the portal (Integration) right after going live.

Most of this list is checked automatically by the wallet conformance test, which plays the part of our game server against your wallet and sends the exact signed calls we send in production, including repeats and a rollback that arrives before its bet:

sh
node tools/wallet-conformance.ts --url https://casino.example/spilvon-wallet \
     --operator op_xxx --secret <wallet secret> --player <a test player with balance> --currency USD \
     --token <a live session token of yours for that player>

The run needs a live session token for the test player (rule 7) and uses a second player id, <player>-conf-other, for the rollback-ownership check.

It leaves the test player's balance where it started and exits with code 0 when every check passes. One check sends a correctly signed jackpot credit whose body names another operator_id; if your wallet wrongly credits it, the run offsets it with a losing round and reports the failure with the fix. It sends separate free-round and jackpot wins with no prior bet and checks that each credits exactly once. With Ed25519, add --signing ed25519: the tool then signs with the public test key of docs/signature-test-vectors.json (key id test-rfc8032-1); make your wallet trust that key for the run only.

The demo casino in this repository can inject wallet failures against a local game server (npm run dev, then the "Wallet failure injection" panel in its lobby).