Errors and response codes
Understand how our server communicates error states
When working with the Partner API, errors can occur for a variety of reasons — from invalid headers to malformed input. This page outlines how we communicate those errors, how you can distinguish between different types, and how to get help if something doesn’t seem right.
🧭 Two types of errors
The Partner API uses GraphQL, which means responses can contain both:
- GraphQL errors – for structural or authentication-level issues
User errors – for problems with your request’s input, like validation failures
1. GraphQL errors
These errors appear in the top-level errors array of the response. They are used to communicate problems with the request itself — typically related to authorization, malformed headers, or server-side issues.
Example
Error Code | HTTP Status | Description |
---|---|---|
INVALID_API_CLIENT | 403 | Used when the supplied X-Ownright-Client-ID header is invalid. |
INVALID_TOKEN | 403 | Used when the supplied access or refresh token is invalid. |
EXPIRED_TOKEN | 403 | Used when the supplied access or refresh token is expired. |
BAD_REQUEST | 400 | Used when the request is incorrectly formatted. |
INTERNAL_SERVER_ERROR | 500 | Used when there is a server error (likely a bug that needs to be fixed). |
When these errors occur, the HTTP status code of the response will reflect the issue (e.g. 403 Forbidden for an invalid token).
2. User errors
User errors are returned inside the data object of a successful GraphQL response. These indicate issues with the input provided — for example, a missing field or an invalid value.
Handling user errors
User errors do not result in a failed HTTP request. The status will be 200 OK but the mutation will have no effect.
Always check for
userErrors
in the response, especially when calling mutations.
You can build resilient integrations by displaying these error messages to your clients or logging them for review.
🏷️ Request ID for debugging
Every Partner API response includes a X-Request-Id
header. If you’re seeing an unexpected error or behavior, please include this Request-Id when contacting support — it allows us to trace and investigate the request quickly.
🛠 Tips for working with errors
Log GraphQL and user errors separately — they represent different classes of problems.
Use GraphQL IDEs (e.g. Insomnia, GraphiQL) to catch schema errors before deployment.
Always include a Request-Id when reporting issues to [email protected].