Game stat API
With Talo, you can track game stats on a per-player basis. For example, you could track the number of secrets discovered by a player or the amount of puzzles they've solved. Talo allows you to easily create and increment these kind of stats.
Learn more about game stats here.
Endpoints
Get all game stats
GET https://api.trytalo.com/v1/game-stats
Headers
None available
Route params
None available
Query keys
None available
Sample response
{ ... }
Get an individual game stat
GET https://api.trytalo.com/v1/game-stats/:internalName
Headers
None available
Route params
Key | Required | Description |
---|---|---|
internalName | ✅ Yes | The internal name of the stat |
Query keys
None available
Sample response
{ ... }
Get a history of changes to a player stat
GET https://api.trytalo.com/v1/game-stats/:internalName/history
Headers
Key | Required | Description |
---|---|---|
x-talo-player | ✅ Yes | The ID of the player |
Route params
Key | Required | Description |
---|---|---|
internalName | ✅ Yes | The internal name of the stat |
Query keys
Key | Required | Description |
---|---|---|
endDate | ❌ No | A UTC Date (YYYY-MM-DD), DateTime (ISO 8601) or millisecond timestamp |
page | ✅ Yes | The current pagination index (starting at 0) |
startDate | ❌ No | A UTC Date (YYYY-MM-DD), DateTime (ISO 8601) or millisecond timestamp |
Sample response
{ ... }
Sample request with filtering
{ ... }
Get a history of changes to a global stat
GET https://api.trytalo.com/v1/game-stats/:internalName/global-history
Headers
None available
Route params
Key | Required | Description |
---|---|---|
internalName | ✅ Yes | The internal name of the stat |
Query keys
Key | Required | Description |
---|---|---|
endDate | ❌ No | A UTC Date (YYYY-MM-DD), DateTime (ISO 8601) or millisecond timestamp |
page | ✅ Yes | The current pagination index (starting at 0) |
playerId | ❌ No | A player ID to use when filtering snapshots |
startDate | ❌ No | A UTC Date (YYYY-MM-DD), DateTime (ISO 8601) or millisecond timestamp |
Sample response
{ ... }
Sample request with filtering
{ ... }
Update a stat value
PUT https://api.trytalo.com/v1/game-stats/:internalName
Sample request
{ ... }
Sample response
{ ... }