The /game/turnready API call is used by a player to set the status of their turn. It is mostly used to set the turn to a "DONE" state, but can also be used to set the turn to a "Not Ready" state. The player provides a security key called the apikey (from the account login API), along with information on the game, player slot and desired turn state.
The following data is accepted by the interface:
Data | Required | Description |
---|---|---|
API Key | Yes | Player's API key from a login request. |
gameid | Yes | The unique number that identifies the game. |
playerid | Yes | The slot number for the player. This is a value between 1 and 35. This must be the player that the API Key is for. |
ready | Yes | The desired state for the turn after this API call completes. This value should be either "True" or "False". |
The following data is returned by the interface:
Data | Description |
---|---|
success | True |
None
This API call is not as polite as many of the other API calls. It informs you that there is an error, but fails to inform you as to which field is missing.
{"success":false,"error":"An API error has occurred - Value cannot be null."}