For the complete documentation index, see llms.txt. This page is also available as Markdown.

Wager-Based Chunk Release

Flow — events & wagering release chunks (PAM → Wynta → PAM)

Chunks move PENDING → RELEASE through two configured mechanisms (see Bonus Lifecycle & Chunk Model for the algorithm):

  1. Release trigger events — any PAM event mapped to a bonus_release_trigger.trigger_type (DEPOSIT, LOGIN, BET_PLACED, TOURNAMENT_WON, …) whose conditions pass.

  2. Wagering progress — when wager_multiplier > 0, bet_placed events feed the per-chunk wagering progress (chunk.wager_amount); a chunk releases when its progress reaches chunk_amount × wager_multiplier.

Trigger: the player wagers; the PAM emits bet_placed with the standard event envelope:

{
  "event_id": "a1b2c3d4-0000-0000-0000-000000000050",
  "event_name": "bet_placed",
  "user_id": "user_001",
  "session_id": "sess_abc123",
  "timestamp": "2026-05-14T19:00:00.000Z",
  "properties": {
    "wager_amount": "250.0000",
    "game_id": "book_of_frosty",
    "game_category": "slots",
    "game_provider": "pragmatic",
    "balance_type": "bonus"
  }
}

Mechanism:

  1. Wynta filters events to the bonus's wager_chip_type and evaluates any BET_PLACED-type release triggers (amount band, product, occurrence, …).

  2. Qualifying wager_amount accrues to the current chunk's wager_amount progress (serialized per player-bonus — no double counting).

  3. Each chunk whose requirement is met moves to RELEASE; overflow progress carries into the next PENDING chunk.

  4. Per released chunk (or batch), Wynta writes a released ledger entry and fires the BONUS_RELEASED webhook; the PAM updates its client wallet — chunk amount moves Pending → Available.

Edge rules:

Case
Behaviour

Large wager crosses several chunk requirements

Multiple chunks release at once; webhook may batch via chunks[]

Voided wager

Progress reduced; released chunks are never clawed back

wager_multiplier = 0

No wagering requirement — chunks release on trigger conditions alone

Wynta unavailable

PAM buffers/replays events (deduped on envelope event_id); release evaluation catches up

Wagering progress display

GET /api/v1/user-bonuses/{user_id}/summary returns wagering_required — the remaining wager amount needed to release all pending chunks — per chip type. The PAM can render a progress bar directly from this field ("₹400 more wagering unlocks your next ₹166.67"), with per-chunk progress (chunks[].wager_amount) available from the transaction-detail endpoint.

Sequence

Last updated

Was this helpful?