Returns a collection of cases that are visible to the authenticated user. Possible values for “status” parameter can be open or closed (if you don't pass nothing both open and closed cases are returned).
{
"continued-at":"/cases?status=open&page=2"
"cases":[
{
"id":"65529188",
"name":"A case",
"type":"case",
...
},
{
"id":"78028991",
"name":"Another case",
"type":"case",
...
},
...
]
}
Returns a single case.
{
"case":{
"id":"65529188",
"name":"A case",
"type":"case",
...
}
}
Creates a new case with the currently authenticated user as the author. By default, a new case is assumed to be visible to everyone. You can also chose to make the case only visible to the creator using “only-me” as the value for the visibility key. Or “group” and pass in a workgroup-id key too. Or “selected-people” and pass an array of id of users that can see the case (note that the creator id is always included). If the account doesn't allow for more cases to be created, a “507 Insufficient Storage” response will be returned.
{
"case":{
"name":"A case",
"visibility":"public",
"case-status":"open",
"attachment":["1672428"],
"involved-people":["62092502", "52829439"]
}
}
Returns HTTP status code 201 (“Created”) on success. The response contain the new case ID. On failure, a non-200 status code will be returned, possibly with error information in JSON format as the response's content.
{
"case-id":"82663335"
}
Updates an existing case with new details from the submitted JSON.
{
"case":{
"visibility":"only-me",
"attachment":["-1672428", "16977387"]
}
}
Returns HTTP status code 200 on success, or any other code (and possibly error information in JSON format) on error.
Destroys the given case.
Returns HTTP status code 200 on success, or any other code (and possibly error information in JSON format) on error.