Error Code

Error Type

The HamsterBase REST API can return two different types of errors under normal operation.

HTTP Level : These errors are indicated by the 4xx code.

Response Level : These errors are contained in the "errors" array of the JSON response.

HTTP Level

Under normal circumstances HamsterBase should only return the following HTTP status code errors.

400 Bad Request: Returned when the request is invalid. This is usually because some required parameter is missing from the request.

401 Unauthorized: Returned when the request requires authentication. Usually because the key is missing from the request header, or because the key is wrong.

404 Not Found: Returned when the requested resource does not exist. Usually because the requested resource does not exist.

Response Level

When the success parameter of the response is set to false, a response level error occurs, which is structured as follows.

interface Response {
  success: false;
  errorCode: string;
  errorMessage: string;
}

E0001

Description Webpage parsing failure

Last Updated: