You can expect the following response codes in general for all endpoints.
GET
- 200 - OK: When getting a object or list of objects
- 404 - Not found: Returned when an object is not found. Could be deleted objects, objects the user don't have access to or when referencing the object with wrong id
POST
- 201 - Created: Successful when objects are created
- 400 - Bad request: Returned when input data is incorrect. This can be invalid json, missing mandatory fields, etc.
- 404 - Not found: Returned when some related object is not found.
PUT
- 201 - Created: Successful when objects are created
- 400 - Bad request: Returned when input data is incorrect. This can be invalid json, missing mandatory fields, etc.
- 403 - Forbidden: Occurs when updating a non existing object or an object the user don't have access to
- 404 - Not found: Returned when some related object is not found.
DELETE
- 204 - No content: Delete was successful, no content is returned
- 403 - Forbidden: Returned when object cannot be found or the user don't have access to the object