If an error occurs when you access Image Processing (IMG), IMG returns an error code and error message. This way, you can locate and fix the error.

Error response format

An example of an error response:

<Error>
  <Code>BadRequest</Code>
  <Message>Input is not base64 decoding. </Message>
  <RequestId>52B155D2D8BD99A15D0005FF</RequestId>
  <HostId>userdomain</HostId>
</Error>

The error response contains the following elements:

  • Code: the error code that IMG returns to the user.
  • Message: the detailed error information provided by IMG.
  • RequestId: the UUID used to identify an error request. When a problem persists, this ID can be sent to the IMG engineers to help locate the cause of the error.
  • HostId: the ID used to identify the accessed IMG cluster.

Error codes

Error code Description HTTP status code
InvalidArgument The error message returned because the parameter is invalid. 400
BadRequest The error message returned because a request error occurs. 400
MissingArgument The error message returned because a required parameter is not specified. 400
ImageTooLarge The error message returned because the image size exceeds the limit. 400
WatermarkError The error message returned because a watermark error occurs. 400
AccessDenied The error message returned because the access is denied. 403
SignatureDoesNotMatch The error message returned because the signature calculated by OSS does not match the signature provided in the request. 403
NoSuchFile The error message returned because the specified image does not exist. 404
NoSuchStyle The error message returned because the specified style does not exist. 404
InternalError The error message returned because an internal error occurs. 500
NotImplemented The error message returned because the method is not implemented. 501

SDK demos for various programming languages