Chest

GetCommonChestReward

URL

https://api.idosgames.com/api/{titleTemplateId}/{titleId}/Client/Chest/GetCommonChestReward  

Description

This action retrieves the reward from a common chest.

HTTP Method

  • POST

Request Body (JSON)

{  
    "WebAppLink": "string",  
    "UsageTime": "int",  
    "ClientSessionTicket": "string",  
    "EntityToken": "string",  
    "UserID": "string"  
}  

Response Codes

  • 200 OK: Returns the ID of the reward item granted.

  • 400 Bad Request: Possible error messages:

    • INVALID_REQUEST_ARGS

    • INVALID_ACTION

    • INCORRECT_TITLE_ID_OR_STATUS_INACTIVE

    • INCORRECT_ACTION

    • INCORRECT_USER_ID

Example Usage

fetch('https://api.idosgames.com/api/{titleTemplateId}/{titleId}/Client/Chest/GetCommonChestReward', {    
    method: 'POST',    
    headers: {    
        'Content-Type': 'application/json'    
    },    
    body: JSON.stringify({    
        WebAppLink: 'https://example.com/?titleID=0',    
        UsageTime: 120,    
        ClientSessionTicket: 'valid-session-ticket',    
        EntityToken: 'valid-entity-token',    
        UserID: 'user-id'    
    })    
})    
.then(response => response.json())    
.then(data => console.log(data))    
.catch(error => console.error('Error:', error));  

GetRareChestReward

URL

https://api.idosgames.com/api/{titleTemplateId}/{titleId}/Client/Chest/GetRareChestReward  

Description

This action retrieves the reward from a rare chest.

HTTP Method

  • POST

Request Body (JSON)

{  
    "WebAppLink": "string",  
    "UsageTime": "int",  
    "ClientSessionTicket": "string",  
    "EntityToken": "string",  
    "UserID": "string"  
}  

Response Codes

  • 200 OK: Returns the ID of the reward item granted.

  • 400 Bad Request: Possible error messages:

    • INVALID_REQUEST_ARGS

    • INVALID_ACTION

    • INCORRECT_TITLE_ID_OR_STATUS_INACTIVE

    • INCORRECT_ACTION

    • INCORRECT_USER_ID

Example Usage

fetch('https://api.idosgames.com/api/{titleTemplateId}/{titleId}/Client/Chest/GetRareChestReward', {    
    method: 'POST',    
    headers: {    
        'Content-Type': 'application/json'    
    },    
    body: JSON.stringify({    
        WebAppLink: 'https://example.com/?titleID=0',    
        UsageTime: 120,    
        ClientSessionTicket: 'valid-session-ticket',    
        EntityToken: 'valid-entity-token',    
        UserID: 'user-id'    
    })    
})    
.then(response => response.json())    
.then(data => console.log(data))    
.catch(error => console.error('Error:', error));  

GetLegendaryChestReward

URL

https://api.idosgames.com/api/{titleTemplateId}/{titleId}/Client/Chest/GetLegendaryChestReward  

Description

This action retrieves the reward from a legendary chest.

HTTP Method

  • POST

Request Body (JSON)

{  
    "WebAppLink": "string",  
    "UsageTime": "int",  
    "ClientSessionTicket": "string",  
    "EntityToken": "string",  
    "UserID": "string"  
}  

Response Codes

  • 200 OK: Returns the ID of the reward item granted.

  • 400 Bad Request: Possible error messages:

    • INVALID_REQUEST_ARGS

    • INVALID_ACTION

    • INCORRECT_TITLE_ID_OR_STATUS_INACTIVE

    • INCORRECT_ACTION

    • INCORRECT_USER_ID

Example Usage

fetch('https://api.idosgames.com/api/{titleTemplateId}/{titleId}/Client/Chest/GetLegendaryChestReward', {    
    method: 'POST',    
    headers: {    
        'Content-Type': 'application/json'    
    },    
    body: JSON.stringify({    
        WebAppLink: 'https://example.com/?titleID=0',    
        UsageTime: 120,    
        ClientSessionTicket: 'valid-session-ticket',    
        EntityToken: 'valid-entity-token',    
        UserID: 'user-id'    
    })    
})    
.then(response => response.json())    
.then(data => console.log(data))    
.catch(error => console.error('Error:', error));  

Last updated

Was this helpful?