Appearance
Sandbox Controls
Registry of all sandbox-only simulation controls. Sandbox is a fully self-contained environment for building and testing your frontend. Every control is
nulloutside sandbox.
Platform time controls (sandbox)
One platform-wide control family (no module owns time):
| Control | Signature | Effect |
|---|---|---|
advanceTime | sdk.sandbox.advanceTime(ms: number): Promise<void> | Moves sandbox time forward by ms, driving every time-based transition platform-wide at once: bonus expiry, promotion scheduling, tournament start/end, tier maintenance and decay, RG limit cooling-off, self-exclusion start and expiry, reality checks |
forceTransition | sdk.sandbox.forceTransition(entity: 'bonus' | 'promotion' | 'tournament' | 'rg-limit' | 'self-exclusion', id: string, targetStatus: string): Promise<void> | Forces one seeded entity directly into a target status, for demonstrating a single transition without moving global time |
Module controls (sandbox)
| Module | Control | Signature | Effect |
|---|---|---|---|
| engagement | simulateWager | simulateWager(amount: number, currency: string, gameId?: string, balanceSource?: 'REAL' | 'BONUS'): Promise<void> | Feeds the wagering pipeline: bonus wagering progress, XP & points, tournament scores. balanceSource defaults to 'REAL'; pass 'BONUS' to prove the real-money-only rule (nothing advances). See Engagement Overview. |
| auth | approveKyc | approveKyc(): Promise<void> | Moves the current user's KYC PENDING → VERIFIED |
| auth | rejectKyc | rejectKyc(): Promise<void> | Moves the current user's KYC PENDING → REJECTED |
| auth | getResetToken | getResetToken(identifier: string): Promise<string> | Retrieves the pending reset token for the given identifier (no email provider in the sandbox) |
| auth | getVerificationCode | getVerificationCode(identifier: string): Promise<string> | Retrieves the pending email/phone verification code for the given identifier (no email/SMS provider in the sandbox) |
| wallet | approveWithdrawal | approveWithdrawal(transactionId: string): Promise<void> | Withdrawal PENDING → COMPLETED; held funds are paid out |
| wallet | rejectWithdrawal | rejectWithdrawal(transactionId: string): Promise<void> | Withdrawal PENDING → REJECTED; held funds return to realBalance |
| wallet | setWalletStatus | setWalletStatus(walletId: string, status: 'ACTIVE' | 'FROZEN' | 'CLOSED'): Promise<void> | Sets wallet status, to demonstrate FROZEN/CLOSED gating |
| wallet | confirmQrDeposit | confirmQrDeposit(transactionId: string): Promise<void> | QR deposit intent → COMPLETED; balance credited; payment event fired |
| wallet | failQrDeposit | failQrDeposit(transactionId: string): Promise<void> | QR deposit intent → FAILED; payment event fired |
| wallet | confirmManualDeposit | confirmManualDeposit(transactionId: string): Promise<void> | Manual bank/crypto deposit PENDING_VERIFICATION → COMPLETED; balance credited; payment event fired |
| wallet | failManualDeposit | failManualDeposit(transactionId: string): Promise<void> | Manual bank/crypto deposit PENDING_VERIFICATION → FAILED; payment event fired |
| engagement | completeRedemption | completeRedemption(redemptionId: string): Promise<void> | Loyalty merch fulfillment: redemption PENDING → COMPLETED (sets shippedAt), so physical-redemption tracking is demonstrable end-to-end |
| engagement | seeds | n/a (data, not a control) | Near-boundary seeds: a bonus expiring in seconds (→ EXPIRED), a promotion activating in seconds (SCHEDULED→ACTIVE), a tournament starting in seconds (UPCOMING→ACTIVE), so time-based UI is demonstrable without any call at all |
| games | completeRound | completeRound(roundId: string, winAmount: number): Promise<void> | Resolves a PENDING round server-side style: PENDING → COMPLETED, writes the WIN ledger entry when winAmount > 0, fires the round-resolved event |
| games | failRound | failRound(roundId: string): Promise<void> | Resolves a PENDING round: PENDING → FAILED; stake returned; fires the round-resolved event |
| messaging | simulateNotification | simulateNotification(type: NotificationType, title: string, body: string): Promise<void> | Delivers a real-time notification through the sandbox in-process channel, also persisted to the inbox |
| messaging | deliverInboxMessage | deliverInboxMessage(type: NotificationType, title: string, body: string): Promise<void> | Adds an inbox message WITHOUT the real-time push, for testing the inbox-read flows alone |
| analytics | getReceivedEvents | getReceivedEvents(): Promise<AnalyticsEvent[]> | Returns every analytics event flushed into the sandbox sink: inspect your tracking without reaching into internals |
Rules
- Controls exist only in sandbox;
sdk.sandboxandsdk.<module>.sandboxarenullin staging/production. - Controls operate on the current sandbox user's data.
- The platform time controls (
sdk.sandbox.advanceTime,forceTransition) cover all time-based transitions across every module, so no behavior requires waiting on a clock to be demonstrated.