Skip to Content

Games

Games represent scheduled matchups with scores and sport-specific stats. The Staty API supports 6 sport types, each with a distinct schema.

Endpoint: /api/v1/games Required scope: read:games (read) / admin (write)

Get teams and rosters in one request by populating both at the same time: ?include=homeTeam.players,awayTeam.players,organization,league. See Query Parameter: ?include= for the full grammar.

Endpoints

MethodPathAuthDescription
GET/api/v1/games?division=:idRecommendedList games for a division
GET/api/v1/games/:idRecommendedGet a single game
GET/api/v1/games?division=:id&include=homeTeam.players,awayTeam.playersRecommendedGames with team rosters
POST/api/v1/gamesRequiredCreate a game
PUT/api/v1/games/:idRequiredUpdate game scores or details

Allowed ?include= roots: homeTeam, awayTeam, organization, league, division.

Common Fields (All Sports)

FieldTypeDefaultDescription
_idObjectIdUnique identifier
datedatenowGame date
timestringGame time string
durationnumber60Duration in minutes
isByebooleanWhether this is a bye game
organizationstringOwning organization ID
leaguestringParent league ID
divisionstringParent division ID
locationstringLocation text
locationModelObjectIdVenue (ref: Location)
gameLabelstringCustom label (e.g. “Game 1”, “Semifinal A”)
playoffRoundstringquarterfinal, semifinal, championship, third_place, consolation
isCancelledbooleanfalseWhether game is cancelled
isHiddenbooleanfalseWhether game is hidden from public views
globalDatestringTimezone-agnostic date string
timeSlotObjectIdScheduled time slot (ref: TimeSlot)
createddateCreation timestamp
updateddateLast update timestamp

Basketball

sport: "basketball"

FieldTypeDescription
homeTeamObjectIdHome team (ref: DivisionTeam)
awayTeamObjectIdAway team (ref: DivisionTeam)
homeTeamPlaceholderstringPlaceholder name (e.g. “Winner Game 3”)
awayTeamPlaceholderstringPlaceholder name
homeScorenumberHome team score
awayScorenumberAway team score

Baseball

sport: "baseball"

FieldTypeDescription
homeTeamObjectIdHome team (ref: DivisionTeam)
awayTeamObjectIdAway team (ref: DivisionTeam)
homeScorenumberHome team score
awayScorenumberAway team score
inningsnumberNumber of innings played

Judo

sport: "judo"

FieldTypeDescription
competitorAObjectIdCompetitor A (ref: Player)
competitorBObjectIdCompetitor B (ref: Player)
winnerObjectIdWinning competitor (ref: Player)
methodstringWin method: ippon, waza-ari, hansoku-make, decision
durationSecondsnumberMatch duration in seconds
weightClassstringWeight class
genderstringmale or female. Default: "male"
roundstringMatch round

Golf

sport: "golf"

FieldTypeDescription
courseNamestringGolf course name
holesnumberNumber of holes. Default: 18
formatstringstroke, match, or stableford. Default: "stroke"

Racket (Tennis, Badminton, etc.)

sport: "racket"

FieldTypeDescription
playerAstring[]Player A IDs (1 for singles, 2 for doubles)
playerBstring[]Player B IDs
teamAObjectIdTeam A (ref: DivisionTeam)
teamBObjectIdTeam B (ref: DivisionTeam)
winnerObjectIdWinning player (ref: Player)
formatstringbest-of-1, best-of-3, best-of-5. Default: "best-of-3"
isDoublesbooleanDoubles match. Default: false
setsSet[]Per-set scores with optional tiebreak

Set Object

{ "setNumber": 1, "playerAScore": 6, "playerBScore": 4, "tiebreak": { "enabled": false } }

Track & Field

sport: "track"

FieldTypeDescription
eventNamestringEvent name (e.g. “100m Sprint”, “Long Jump”)
resultTypestringtime, distance, or points
genderstringmale, female, or mixed. Default: "mixed"
isRelaybooleanWhether this is a relay event. Default: false
previewStatsbooleanShow preview stats. Default: true
participantsstring[]Participant player IDs

Example: List Games with Players

curl "https://api.staty.io/api/v1/games?division=div_def456&include=homeTeam.players,awayTeam.players" \ -H "Authorization: Bearer sk_live_..."

Response:

{ "success": true, "data": [ { "_id": "game_abc", "sport": "basketball", "date": "2026-04-10T19:00:00.000Z", "duration": 60, "homeTeam": { "_id": "divteam_1", "name": "Thunder", "players": [ { "_id": "player_1", "name": "Alex Johnson", "number": "7" } ] }, "awayTeam": { "_id": "divteam_2", "name": "Lightning", "players": [ { "_id": "player_2", "name": "Sam Lee", "number": "11" } ] }, "homeScore": null, "awayScore": null } ], "count": 1 }
Last updated on