Types¶
These are the types of JSON entity the server may return/accept, as referenced elsewhere in the docs.
Timer
¶
The state of a game timer.
Fields:
id
:int
turn_number
:int
(note that this is updated once every turn, rather than just once every round - for each turn one user takes, the turn number will be two higher)turn_started_at
:datetime
ornull
, the time the current turn started (see below)started_at
:datetime
ornull
, the time the first move started (see below)has_ended
:bool
end_reporter
:UserPosition
(see below) ornull
, the side that reported the end, if the game was ended early.home
:TimerSide
(see below) ornull
away
:TimerSide
(see below) ornull
settings
:array
ofStageSettings
(see below)observers
:int
managed
:boolean
TimerSide
¶
The state of one side of a timer.
Fields:
is_turn
:boolean
total_time
:timedelta
as of the start of the last turn, see belowconnected
:boolean
StageSettings
¶
Settings for one stage of a timer.
Fields:
start_turn
:timedelta
(see below)seconds_fixed_per_turn
:timedelta
(see below)seconds_incremement_per_turn
:timedelta
(see below)initial_seconds
:timedelta
(see below)
AppStats
¶
Stats relating to usage of the app.
Fields:
all_timers
:int
ongoing_timers
:int
connected
:int
UserPosition
¶
An int
defining the position of a user in a game. Possible values:
-2
: Observer-1
: Manager0
: Home1
: Away
Note that there is currently no situation in which -2
would be used.
timedelta
¶
This is a real
, representing a number of seconds.
datetime
¶
Like a timedelta
, but represents seconds since the Unix epoch.