Loyalty API v2 - Error Responses

Contents

Overview

If an error occurs when calling any of the Loyalty API endpoints, an error response will be returned with a standard response format (see below). Use the HTTP error code in coordination with the code field to determine the specific scenario that generated that error code, which will be listed in the corresponding endpoint documentation.

Format

The error response format used by the Loyalty API is the same as all other Partner API endpoints.

  • status <integer>: the HTTP status code.

  • code <string>: descriptive error code, used to differentiate error scenarios that return the same HTTP status code. This error code is also returned under errors[0].code.

  • message <string>: human readable error message, in English. This error message is also returned under errors[0].message.

  • errors: array of error objects.

Common Errors

In addition to specific endpoint errors, the following common errors could be generated by the Loyalty API:

This section is under design. We will add here all common errors, e.g. 500 (Internal Server Error), 503 (Service Unavailable).

  • TBC