GameCenter Web Api

<back to all web services

CreateGame

Create or update a game; will update if the CreatorGuid matches an existing game, but will only allow changes to the following fields: StartDateTime/LocalStartDateTime, TimeZone, GameType, and Home/AwayTeamSeasonId (as long as they are the same as before but swapped with each other); if CreatorGuid is missing or new, a new game will be created

The following routes are available for this service:
POST/games/new

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/CreateGame HTTP/1.1 
Host: api.digitalscout.com 
Content-Type: application/json
Content-Length: length

{"AwayTeamSeasonId":0,"DeviceId":"String","GameType":"Preseason","HomeTeamSeasonId":0,"LocalStartDateTime":"String","Sport":"Football","StartDateTime":"String","TimeZone":"String"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"Game":{"AwayTeamSeasonId":0,"CurrentQuarter":0,"DeletedOn":"0001-01-01 00:00:00 +00","GameId":0,"GameType":"Preseason","HomeTeamSeasonId":0,"QuarterSecondsLeft":0,"Sport":"Football","Status":"Scheduled","StatusText":"String","TimeZone":"String"}}