Game**
Generate a Unique URL for Playing a Game
POST /users/{user_id}/games/play
This API is used to generate a unique URL that allows a specific user to access and play a game. The generated URL is time-sensitive and will expire after ⚠️ 30 minutes, after which a new URL must be generated to continue.
Body
lang
string (optional)
"en" (default), "es"
game
string (optional)
"prizewheel" (default), "truck", or "flight"
Response
{
"status": "success",
"url": string, // Unique URL for the user to play the game,
"lang": string, // enum("en", "es")
"expiry_time": string // ISO 8601 format
}{
"status": "error",
"message": string //e.g "lang: Input should be a valid string"
}List Game Outcomes for User
GET /users/{user_id}/games/history
This API retrieves a history of game outcomes for a specific user. It provides details about each game outcome, including the prize won, the timestamp of the game, and a pagination token for retrieving additional results if the list is long.
Query Parameters
limit
number (optional)
Page size (default 10)
next_token
string (optional)
Pagination token to get next set of results.
Response
{
"status": "success",
"items": [
{
"id": string,
"user_id": string,
"play_type": string, // enum('regular', 'amoe')
"prize": {
//
// Only one of these objects will be returned
//
"entry_truck": number, // number is always 1
"entry_flight": number, // number is always 1
"prize_money_transfer": number, // always 1
"prize_cash_back": number, // always 1
"prize_streaming": number, // always 1
"prize_imt": number, // always 1
"prize_gift_card": number, // always 1
"prize_phone_accessory": number, // always 1
"prize_merchandise": number, // always 1
"tickets": number,
"cash_usd": number
},
"timestamp": string, // ISO 8601 format
"result_effective_date": string // ISO 8601 format
}
],
"next_token": string // returns "" if it's the last page
}{
"status": "error",
"message": string //e,g "Invalid next_token"
}Check User's Play Eligibility
GET /users/{user_id}/game/check-eligibility
Checks a user's eligibility to play without starting a new game session.
Body
The body of this request should be empty
Response
{
"status": "success",
"playable": boolean, // "true" or "false"
"restrictions": [string] // possible values: "tickets_only","daily_spin_limit_reached","insufficient_tickets"
}Last updated
Was this helpful?