Game parts are the relationship between Games and Parts.
Each gamepart has the following properties. Complete details in GamePartProperties.
The unique id for this gamepart. It will never change.
gamepart
.
A date when the gamepart was created.
A date when the gamepart was last updated.
An integer between 1 and 99.
Defaults to 1
.
Allows for multiple copies of a gamepart to be included in the game.
A Game id. The id of the game associated with this gamepart.
A Part id. The id of the part associated with this gamepart.
A hash that is a brief representation of the part associated with this gamepart. It is provided so that when you get the list of gameparts for a game, you don't also have to make a call to Part.
The methods used to fetch and manipulate gameparts.
POST /api/gamepart
Required. The unique session id provided by a Session method.
Required.
NOTE: Multiple parts of the same part_id
are not allowed as separate part gamepart entries. Therefore if you try to create a new game part with a part_id that already exists in the game, it will update the existing gamepart and return that as the result.
Required.
Optional.
Returns:
{ "id" : "xxx", "part" : { ... }, ... }
PUT /api/gamepart/xxx
See Create Game Part for details.
DELETE /api/gamepart/xxx
Required. The unique session id provided by a Session method.
Returns:
{ "success" : 1 }
GET /api/gamepart/xxx
Optional. The unique session id provided by a Session method.
Optional. See "Relationships" in Intro and Game Part Relationships above for details.
Returns:
{ "id" : "xxx", "part" : { ... }, ... }