We hold each player’s balance.
You credit and debit players with one API call each. Bets and settlements move the balance for you.
- Credit, debit and read any balance through the API.
- Idempotency keys make every retry safe: an operation applies at most once.
- Load a balance before the player’s first session.
- The quickest integration: if your server can call an API, you’re set.
API=https://api.thesportsbook.app/b2b/v1curl -X POST "$API/users/viewer-42/credit" \ -H "Authorization: Bearer $SPORTSBOOK_API_KEY" \ -H "Content-Type: application/json" \ -d '{"amount": 50, "idempotency_key": "topup-8f1c2"}'# {"balance": 150, "operation_id": "5b0c…",# "replayed": false}Best when your tokens only need to exist inside the sportsbook.