Game Result Webhook Handler

Header Parameters :

  • X-Client-ID : unique id given by admin to identify game's identity.

  • X-Signature : HMAC Signature of the payload using the game's unique secret key.

  • X-Timestamp : unique timestamp.

🔐 Security & Integrity

  1. HMAC Signature Verification

    • Ensures that all incoming game session events are properly signed using a pre-shared secret.

  2. Replay Attack Prevention

    • Uses timestamps and unique signatures to prevent the same event from being processed multiple times.

Payload :

{
    roomId: ROOM_ID,
    sessionResults: [
        { userId: 1, rankUpdate: 10, winner: true },
        { userId: 2, rankUpdate: 10, winner: false }
    ]
}

Client Example ( Node.js )

Last updated