Skip to main content
All docs

Timer API reference

Every timer endpoint of the KeepTheScore API, with its parameters, request body and responses, generated from the live API.

Keys, tokens, request bodies and rate limits are explained in the API guide. In the paths below, {token} is a board token when you send an API key, or one of the board's own tokens without one.

This page is generated from the live API. The same reference is available as OpenAPI 3 at /apispec.json, if you'd rather generate a client than read tables.

Timer

POST /api/v1/sport/{token}/timer/adjust

Adjust the main timer duration by a specified number of seconds.

Body: {"amount": <seconds>} - positive to add time, negative to subtract. The timer duration will not go below 0.

Path parameters

NameTypeRequiredDescription
token string yes

Responses

StatusMeaningBody
200 OK MessageResponse
400 Malformed request —
403 This token does not allow the board to be edited —
404 Board not found —
429 Too many requests —
500 Internal server error —

Response body (200) — MessageResponse (JSON)

FieldTypeAlways presentDescription
message string yes Status message
POST /api/v1/sport/{token}/timer/reset

Reset the main timer to its initial duration.

Path parameters

NameTypeRequiredDescription
token string yes

Responses

StatusMeaningBody
200 OK MessageResponse
400 Malformed request —
403 This token does not allow the board to be edited —
404 Board not found —
429 Too many requests —
500 Internal server error —

Response body (200) — MessageResponse (JSON)

FieldTypeAlways presentDescription
message string yes Status message
POST /api/v1/sport/{token}/timer/toggle

Toggle the main timer for any sport scoreboard.

Sport-specific behavior: - Basketball: Also syncs the shot clock (starts/stops with main timer)

Path parameters

NameTypeRequiredDescription
token string yes

Responses

StatusMeaningBody
200 OK MessageResponse
400 Malformed request —
403 This token does not allow the board to be edited —
404 Board not found —
429 Too many requests —
500 Internal server error —

Response body (200) — MessageResponse (JSON)

FieldTypeAlways presentDescription
message string yes Status message