Last updated

API Error Handling

Our API uses a consistent error-handling structure. When an error occurs, the response will:

Include the appropriate HTTP status code (e.g., 400, 404, 500)

Contain an optional error field with the following schema:

{
    "error": {
        "code": "3002",                         //The error code,
        "message":"Request validation failed.", //The error message.,
        "details": "validation errors"         //The HTTP error details.
    }
}

Error Codes

Playout API Error Codes

  • 1001EPISODE_NOT_FOUND: The requested episode does not exist.
  • 1002DESCRIPTIONS_NOT_AVAILABLE: Descriptions and further details for the requested episode are currently unavailable.
  • 1003EPISODE_NOT_AVAILABLE: The episode exists but cannot be accessed at this time.
  • 1004AFFILIATE_NOT_AVAILABLE: The affiliate information could not be retrieved.
  • 1005MERCHANTS_NOT_AVAILABLE: The merchant list for the episode is unavailable.
  • 1006MERCHANT_NOT_FOUND: The specified merchant does not exist.
  • 1007TIMELINE_NOT_AVAILABLE: No timeline data is available for the episode.
  • 1008SCENE_NOT_FOUND: The requested scene could not be found in the episode.
  • 1009DATA_NOT_FOUND: The expected data could not be located.

Basket API Error Codes

  • 2001PAYMENT_PROVIDER_NOT_SUPPORTED: The provided payment method is not supported.
  • 2002AUTHORIZATION_HEADER_INVALID: The authorization header is missing or malformed.
  • 2003AFFILIATE_NOT_EXISTS: The affiliate identifier does not match any known affiliate.
  • 2004MISSING_AFFILIATE: The request is missing required affiliate context.

Generic API Error Codes

  • 3001INTERNAL_SERVER_ERROR: An unexpected error occurred on the server.
  • 3002REQUEST_VALIDATION_ERROR: The request did not pass input validation rules.

Product API Error codes

  • 4001 - NOT_A_MANAGED_SHOP: The shop is not managed by the marketplace.