API Errors

Error Response Format

All error responses contain at least the top level error object with httpCode and message
  • httpCode - HTTP status code
  • message - Human readable message indicating why the api request failed



Workaround for clients that always need 200 HTTP status code returned (e.g. Flash)

Passing the force_http_success=true URL parameter on any resource request will force a HTTP "200 Success" response.  If the request was invalid or caused an error, the client may inspect the error.httpCode and error.message for the true result of their request.



HTTP Response Codes

The complete set of HTTP response codes that the Groupon API may return:

200 OK: Success!
400 Bad Request: The request was invalid for reasons other than authentication.
401 Unauthorized: Authentication credentials were missing or incorrect.
    Returned from POST /oauth/access_token if client_id, username, password are missing or incorrect
    Returned from any authenticated request that is missing the access_token
403 Forbidden: The request is understood, but was refused because the requestor does not have the correct rights to perform the action requested.
404 Not Found: A specified instance of a resource that does not exist has been requested. Note: incorrect parameters for a request will result in a 400 response.
500 Internal Server Error: Something unexpected happened on the server. Contact support.
503 Service Unavailable: Groupon is currently unavailable to fulfill your request.

** All non-200 responses contain the standard response body that will explain the error.
Comments