iDos Games Docs
  • Welcome
  • Getting Started
    • Quick Start
    • Telegram Mini Apps
  • Settings
    • Dashboard
    • Platform Settings
    • Secret Key
    • In App Purchase
    • Crypto
    • Email
    • AI Services
    • Integrations
  • LiveOps
    • Title Config
    • Title Data
    • Users
    • Catalogs
    • Currency
    • Shop
    • Leaderboard
    • Weekly Events
    • Rewards
    • Marketplace
    • Referral System
  • API
    • Authentication
    • User Data
    • Crypto Wallet
    • Referral
    • Chest
    • Friend
    • Marketplace
    • Purchase
    • Reward
    • Shop
    • Spin
    • Time Limited Event
    • Subscription
    • Server API
    • Admin API
Powered by GitBook
On this page
  • GetUserAllData
  • GetUserInventory
  • UpdateCustomUserData
  • DeleteTitlePlayerAccount
  • UpdateLeaderBoard
  • GetCatalogItems
  • GetLeaderboard
  • GetServerTime

Was this helpful?

  1. API

User Data

GetUserAllData

Purpose

Retrieves all user data based on the provided user ID.

URL

https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/GetUserAllData  

Method

  • GET or POST

Request Parameters (JSON body)

  • userID (string): The unique identifier of the user.

Responses

  • 200 OK: Successful retrieval. Returns a GetAllUserDataResult object with user data.

  • 400 Bad Request: If there is an error in retrieving the data.

Example Usage

Request:

fetch('https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/GetUserAllData', {    
    method: 'POST',    
    headers: {    
        'Content-Type': 'application/json'    
    },    
    body: JSON.stringify({    
        userID: 'existing-user-id'    
    })    
})    
.then(response => response.json())    
.then(data => console.log(data))    
.catch(error => console.error('Error:', error));  

Response:

{  
    "UserID": "existing-user-id",  
    "CustomUserData": {  
        "DataVersion": 1,  
        "Data": {}  
    },  
    ...  
}  

GetUserInventory

Purpose

Retrieves the inventory of a user.

URL

https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/GetUserInventory  

Method

  • GET or POST

Request Parameters (JSON body)

  • userID (string): The unique identifier of the user.

Responses

  • 200 OK: Successful retrieval. Returns a GetUserInventoryResult object with inventory data.

  • 400 Bad Request: If there is an error in retrieving the inventory.

Example Usage

Request:

fetch('https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/GetUserInventory', {    
    method: 'POST',    
    headers: {    
        'Content-Type': 'application/json'    
    },    
    body: JSON.stringify({    
        userID: 'existing-user-id'    
    })    
})    
.then(response => response.json())    
.then(data => console.log(data))    
.catch(error => console.error('Error:', error));  

Response:

{  
    "Inventory": [  
        {  
            "ItemID": "item-1",  
            "Quantity": 5  
        },  
        ...  
    ]  
}  

UpdateCustomUserData

Purpose

Updates custom user data with the provided key-value pair.

URL

https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/UpdateCustomUserData  

Method

  • POST

Request Parameters (JSON body)

  • key (string): Key of the custom user data to update.

  • value (string): New value for the custom user data.

Responses

  • 200 OK: Successful update. Returns a success message.

  • 400 Bad Request: If there is an error in the update request.

Example Usage

Request:

fetch('https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/UpdateCustomUserData', {    
    method: 'POST',    
    headers: {    
        'Content-Type': 'application/json'    
    },    
    body: JSON.stringify({    
        key: 'customKey',    
        value: 'customValue'    
    })    
})    
.then(response => response.json())    
.then(data => console.log(data))    
.catch(error => console.error('Error:', error));  

Response:

{  
    "Message": "SUCCESS"  
}  

DeleteTitlePlayerAccount

Purpose

Deletes the account of a player in a specific title.

URL

https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/DeleteTitlePlayerAccount  

Method

  • POST

Request Parameters (JSON body)

  • userID (string): The unique identifier of the user.

Responses

  • 200 OK: Successful deletion. Returns a success message.

  • 400 Bad Request: If there is an error in the deletion request.

Example Usage

Request:

fetch('https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/DeleteTitlePlayerAccount', {    
    method: 'POST',    
    headers: {    
        'Content-Type': 'application/json'    
    },    
    body: JSON.stringify({    
        userID: 'existing-user-id'    
    })    
})    
.then(response => response.json())    
.then(data => console.log(data))    
.catch(error => console.error('Error:', error));  

Response:

{  
    "Message": "SUCCESS"  
}  

UpdateLeaderBoard

Purpose

Updates the leaderboard score for a user.

URL

https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/UpdateLeaderBoard  

Method

  • POST

Request Parameters (JSON body)

  • userID (string): The unique identifier of the user.

  • amount (int, optional): The amount to update the leaderboard score by. Default is 1.

Responses

  • 200 OK: Successful update. Returns a success message.

  • 400 Bad Request: If there is an error in the update request.

Example Usage

Request:

fetch('https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/UpdateLeaderBoard', {    
    method: 'POST',    
    headers: {    
        'Content-Type': 'application/json'    
    },    
    body: JSON.stringify({    
        userID: 'existing-user-id',    
        amount: 5    
    })    
})    
.then(response => response.json())    
.then(data => console.log(data))    
.catch(error => console.error('Error:', error));  

Response:

{  
    "Message": "SUCCESS"  
}  

GetCatalogItems

Purpose

Retrieves the catalog items for a specific catalog version.

URL

https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/GetCatalogItems  

Method

  • GET or POST

Request Parameters (JSON body)

  • catalogVersion (string): The version of the catalog to retrieve items from.

Responses

  • 200 OK: Successful retrieval. Returns a list of catalog items.

  • 400 Bad Request: If there is an error in retrieving the catalog items.

Example Usage

Request:

fetch('https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/GetCatalogItems', {    
    method: 'POST',    
    headers: {    
        'Content-Type': 'application/json'    
    },    
    body: JSON.stringify({    
        catalogVersion: 'v1'    
    })    
})    
.then(response => response.json())    
.then(data => console.log(data))    
.catch(error => console.error('Error:', error));  

Response:

{  
    "CatalogItems": [  
        {  
            "ItemID": "item-1",  
            "Name": "Sword",  
            "Price": 100  
        },  
        ...  
    ]  
}  

GetLeaderboard

Purpose

Retrieves the leaderboard data for a specific leaderboard ID.

URL

https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/GetLeaderboard  

Method

  • GET or POST

Request Parameters (JSON body)

  • leaderboardID (string): The ID of the leaderboard to retrieve data from.

Responses

  • 200 OK: Successful retrieval. Returns leaderboard data.

  • 400 Bad Request: If there is an error in retrieving the leaderboard data.

Example Usage

Request:

fetch('https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/GetLeaderboard', {    
    method: 'POST',    
    headers: {    
        'Content-Type': 'application/json'    
    },    
    body: JSON.stringify({    
        leaderboardID: 'leaderboard-1'    
    })    
})    
.then(response => response.json())    
.then(data => console.log(data))    
.catch(error => console.error('Error:', error));  

Response:

{  
    "Leaderboard": [  
        {  
            "UserID": "user-1",  
            "Score": 1500  
        },  
        ...  
    ]  
}  

GetServerTime

Purpose

Retrieves the current server time.

URL

https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/GetServerTime  

Method

  • GET

Responses

  • 200 OK: Successful retrieval. Returns the current server time.

Example Usage

Request:

fetch('https://api.idosgames.com/api/[titleTemplateId]/[titleId]/Client/UserData/GetServerTime', {    
    method: 'GET',    
    headers: {    
        'Content-Type': 'application/json'    
    }  
})    
.then(response => response.json())    
.then(data => console.log(data))    
.catch(error => console.error('Error:', error));  

Response:

{  
    "ServerTime": "2023-04-01T12:00:00Z"  
}  
PreviousAuthenticationNextCrypto Wallet

Last updated 6 months ago

Was this helpful?