Eksportér (0) Udskriv
Udvid alt
EN
Dette indhold er ikke tilgængeligt på dit sprog, men her er den engelske version.

Status and Error Codes

Updated: July 2, 2014

REST API operations for Azure storage services return standard HTTP status codes, as defined in the HTTP/1.1 Status Code Definitions.

API operations may also return additional error information that is defined by the storage service. This additional error information is returned in the response body.

The body of the error response follows the basic format shown here. The code element indicates the storage service error code string, whereas the message element indicates the error message string.

<?xml version="1.0" encoding="utf-8"?>
<Error>
  <Code>string-value</Code>
  <Message>string-value</Message>
</Error>

A given error response may also include additional error information to provide the developer with more information about the error. For example, the following error response indicates that a query parameter specified on the request URI was invalid, and provides additional information about the invalid parameter's name and value and the reason for the error.

<?xml version="1.0" encoding="utf-8"?>
<Error>
  <Code>InvalidQueryParameterValue</Code>
  <Message>Value for one of the query parameters specified in the request URI is invalid.</Message>
  <QueryParameterName>popreceipt</QueryParameterName>
  <QueryParameterValue>33537277-6a52-4a2b-b4eb-0f905051827b</QueryParameterValue>
  <Reason>invalid receipt format</Reason>
</Error>

The following topics provide lists of error codes for the Blob, Queue, Table, and File services:

Error responses for the Table service include the storage services error code and message elements, as shown above, but are also compliant with the error format described in section 19 of the OData specification. Additional error information may be included in the response in addition to the storage services error code and message, but the error response will always comply with the OData spec.

Batch error responses are similar to standard Table service error responses and are described in detail in Performing Entity Group Transactions.

Basic Error Body in Atom Format

<?xml version="1.0" encoding="utf-8"?>
<error xmlns="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">
  <code>ResourceNotFound</code>
  <message xml:lang="en-US">The specified resource does not exist.
RequestId:e288ba1e-f5dd-4014-9e09-f1263d223dec
Time:2014-06-04T16:18:20.7088013Z</message>
</error>

Basic Error Body in JSON Format

{"odata.error":{"code":"ResourceNotFound","message":{"lang":"en-US","value":"The specified resource does not exist.\nRequestId:102a2b55-eb35-4254-9daf-854db78a47bd\nTime:2014-06-04T16:18:20.4307735Z"}}}

See Also

Vis:
© 2014 Microsoft