GameCenter Web Api

<back to all web services

UpdatePartnerGameScores

Updates the scores for a game. GameId, PublisherId, and the Scores array are required, the other fields are optional but encouraged. Enum values: ClockStatus: GameNotStarted, Running, PeriodEnded, Timeout, InjuryTimeout, OfficialTimeout, GameEnded, Delayed, Postponed; for Period and CurrentPeriod: 1-4, OT continues with periods 5-8; if halves, use 1-2 and 3-6 for OT; GameStatus: Scheduled, Delayed, Postponed, InProgress, Cancelled, Complete; PeriodSecondsLeft: an example would be a value of 124 to indicate 2:04 left in the current period, 0 if the period is over

The following routes are available for this service:
PUT/partner/games/{GameId}/scores

To override the Content-type in your clients HTTP Accept Header, append the .json suffix or ?format=json

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /json/reply/UpdatePartnerGameScores HTTP/1.1 
Host: api.digitalscout.com 
Content-Type: application/json
Content-Length: length

{"ClockStatus":"GameNotStarted","CurrentPeriod":0,"GameId":"String","GameStatus":"Scheduled","PeriodSecondsLeft":0,"PublisherId":"String","Scores":[{"IsFinal":false,"Period":0,"SchoolId":"String","Score":0}]}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"ClockStatus":"GameNotStarted","CurrentPeriod":0,"GameStatus":"Scheduled","GameType":"Preseason","HomeSchoolId":"String","HtmlUrl":"String","Id":"String","Participants":[{"Gender":"Male","Level":"Freshman","SchoolId":"String"}],"PeriodSecondsLeft":0,"Scores":[{"IsFinal":false,"Period":0,"SchoolId":"String","Score":0}],"Sport":"Football"}