Skip to content

Error Handling

The Allawee API uses HTTP status codes and messages to let you know whether your API call was successful or failed. If your request fails, the API returns a status code, code, and message to let you know why the request failed. You can use these codes and messages to know what went wrong and how to work around it.

Status Codes

There are three ranges of status codes you can expect:

  • 2**: This code shows that your request was successful and worked as expected.
  • 4**: This code shows that there is something wrong with your request.
  • 5**: This code shows that a problem occurred with the server while it was processing your request.

Some status codes you may see and what they mean are as follows.

CodeTitleDescription
200OkEverything worked as expected.
400Bad RequestThe request was unacceptable, often due to missing a required parameter.
401UnauthorisedNo valid API key provided.
402Request failedThe parameters were valid but the request failed.
403ForbiddenThe API key doesn’t have permission to perform the request.
404Not foundThe requested resource doesn’t exist.
500, 503, 504Server errorsSomething went wrong on Allawee’s end. These are rare.

Error Messages

You can also use the message you get to know if your request was successful. If your request failed, it will tell you why your request failed. Any other message besides “Success” is an error message. Here are some common errors and possible solutions.

MessageProblemFix
Authorization RequiredYou did not include a header or your header does not have a user token.Include an Authorization header with your user token.
Invalid Authorization KeyYour authorization key is incorrect.Make sure that you are using the correct user token.
Invalid Authorization TypeYou are not including your authorization key as a Bearer token.Ensure that you precede your token with “Bearer ”.
Malformed Authorization KeyYour user token is not in the proper format.Make sure that you are using the correct user token.
Application TimeoutOur server timed out.Make your request again.
Request TimeoutYour request timed out.Make your request again.
Service UnavailableThe server is unavailable.
Trial EndedYour trial has ended.Pay to use the service.

Last updated Aug. 01, 2023

Next Up: Testing
Page Outline