Skip to content

Latest commit

 

History

History
11 lines (11 loc) · 4.06 KB

endpoints.md

File metadata and controls

11 lines (11 loc) · 4.06 KB
Was created URL HTTP request Purpose Client Request Body Server Body Response Server HTTP Response Header Auth Security Notes
Y /api/game GET Get game by id JSON object of game 200 - successful
Y /api/game/{id} PUT Update game data JSON Object - game (including array of platformIDs where game is available) JSON Object - updated game object including gameID 200 - successful JWT token with relevant permissions(ADMIN) ADMIN permission
Y /api/platforms GET Get list of All Platforms JSON Array of Platform Objects 200 - successful
Y /api/platforms/filter?gameid=3 GET Get platforms using a filter query JSON Array of Platform Objects 200 - successful
Y /api/platform/{id} GET Get platform details by ID JSON Object of platform details 200 - successful
/api/game POST Create game JSON Object - game to be created JSON Object - newly created game object with new gameID 201 Created if successful or not authorized if not authorized... JWT token with relevant permissions(ADMIN) ADMIN permission
/api/games/filter?platformid=4 GET Get list of games by filter JSON Array of Game Objects (could be paginated?) 200 successful JWT token regular user
/api/collection POST Add item to collection JSON object including the game id, platform owned, digital or physical JSON of the new game owned object (or array?) and use the Principal principal 201 - successfully created JWT token regular user
/api/search?game={game}&platform={platform} GET Search by game name and optional platform JSON Array of matching games 200 - successful JWT token regular user