-
Notifications
You must be signed in to change notification settings - Fork 5
Error handling
Ryan Newington edited this page Apr 25, 2018
·
4 revisions
The API returns the following response codes. Note that IIS or the WCF stack may return codes in addition to those shown here
Code | Description |
---|---|
200 | The operation completed successfully |
202 | The operation completed, but is pending authorization |
400 | The request was malformed or incomplete |
403 | The user was not authorized to perform the operation |
404 | The specified resource could not be found |
500 | An internal error occurred |
The body of the response may return an ExceptionDetail object that contains details about the error that was encountered.
Code | Description |
---|---|
200 | The operation completed successfully |
201 | The resource was created successfully |
202 | The operation completed, but is pending authorization |
204 | The operation completed successfully, and there is no content returned |
400 | The request was malformed or incomplete |
403 | The user was not authorized to perform the operation |
404 | The specified resource could not be found |
500 | An internal error occurred |
The body of the response may contain an error record that contains details about the error that was encountered. The error object is structured as follows
{
"error": {
"code": "resource-not-found",
"message": "The specified resource was not found",
"target": null,
"details": null
}
}
Field | Description |
---|---|
code | A string-based error code. See the error code table below for supported error codes |
message | A message indiciating the error condition |
target | The correlation-id provided by the resource management service, if available |
details | Reserved for future usage |
Code | Description |
---|---|
bad-request | The request was not valid |
resource-management-exception | The request caused an exception in the resource management service |
interal-server-error | A internal server error ocurred |
resource-not-found | The specified resource was not found |