Thursday, May 30, 2013

HTTP status codes

As part of an ongoing effort to conform our web API design to industry best practices, we decided to take a closer look at the HTTP status codes that Eva returns.
The following is a list of the codes we currently use:
  • 200 OK = The request has succeeded. 
  • 400 BAD REQUEST = faulty values in the request parameters.
    Most often returned when the input_text field is empty.
  • 401 UNAUTHORIZED = The request requires user authentication, which failed.
    Please check the site_code and api_key request parameters.
  • 404 NOT FOUND = The server has not found anything matching the Request.
  • 405 METHOD NOT ALLOWED =  Eva currently supports only "HTTP GET" requests. 
  • 429 TOO MANY REQUESTS = The site_code quota has been exceeded.  See
  • 500 INTERNAL SERVER ERROR = A bug escaped us. Sorry. We are on it.
Please make sure your code can handle these return codes.

No comments:

Post a Comment