Portail développeurs

Portail développeurs / Guides

Documentation technique en anglais

VERIFICATION

Wallet conformance

The conformance test plays the part of our game server. It sends the exact signed calls we send in production to your wallet, including the awkward ones:

  • repeats;
  • a forged signature;
  • a stale timestamp;
  • a rollback that arrives before its bet;
  • a free-round win and a separate jackpot credit (kind: "jackpot"), neither requiring a prior bet.

It leaves the test player's balance where it started.

sh
# HMAC. --token must be a LIVE casino session token of the test player (a made-up one must be refused)
node tools/wallet-conformance.ts --url https://casino.example/spilvon-wallet \
     --operator op_xxx --secret <wallet secret> --player <test player with ≥ 10 units> \
     --token <live session token> --currency USD

# Ed25519: your wallet must trust the public RFC 8032 test key (kid "test-rfc8032-1") for the run
node tools/wallet-conformance.ts --signing ed25519 --url https://casino.example/spilvon-wallet \
     --operator op_xxx --player <test player> --token <live session token> --currency USDT

Exit code 0 means every check passed (Ed25519 mode also checks an unknown signing key id). The tool also reads the balance of a second player, <player>-conf-other, to prove a rollback cannot credit the wrong account. The tool currently ships inside the SPILVON repository and needs Node 22.18 or newer. Ask your SPILVON contact for the standalone file until it is published on the developer portal.

The Node, Python and Go samples were checked with this tool on 2026-11-30 in both signing modes, and all checks passed. To run them, set SPILVON_SAMPLE_TOKENS='{"<token>":"<player>"}'; that stands in for your session store.

To exercise the wallet by hand, use the Wallet simulator folder of the Postman collection:

  1. Set walletUrl and walletSecret.
  2. Run Prepare ids.
  3. Send bet, then win (send each twice), then rollback.