Response status codes and how the API deals with errors

Meya uses conventional HTTP response codes to indicate the success or failure of an API request. In general, codes in the 2xx range indicate success, codes in the 4xx range indicate an error that failed given the information provided (e.g., a required parameter was omitted, your account isn't authorized, etc.), and codes in the 5xx range indicate an error with Meya's servers (these are rare).

HTTP status code summary

Status codeDescription
200 - OKEverything worked as expected.
201 - CreatedResource was successfully created. ex. create a new user
202 - AcceptedRequest was accepted, but not yet processed. ex. /receive
204 - No contentRequest was successful, but no response provided. ex. DELETE resource
400 - Bad requestThe request was unacceptable, often due to missing a required parameter.
401 - UnauthorizedUnauthorized access to resource
403 - ForbiddenInvalid api key or similar
404 - Not FoundResource doesn't exist
409 - ConflictThe request conflicts with another request. Attempting to add the same user 2x for example.
429 - Too many requestsToo many requests hit the API too quickly. We recommend an exponential backoff of your requests or upgrade to paid plan.