UNAUTHORIZED
Summary
This error corresponds to the standard 401 Unauthorized
HTTP status code, indicating that the request lacks valid authentication credentials for the requested resource.
Example Response
{
"code": "UNAUTHORIZED",
"type": "https://docs.leyr.io/api/error-handling/unauthorized",
"title": "Unauthorized",
"status": 401,
"detail": "Application with the provided client ID was not found.",
"instance": "36f6904c-fd11-4ea9-8f74-a103fc829bd1"
}
Common Causes
- Missing
x-leyr-client-id
header in the request - Invalid
x-leyr-client-id
header - the specified application ID doesn't exist - Incorrect authentication credentials for the requested endpoint
Resolution Steps
To resolve this error:
- Check the
detail
field in the response body. It contains specific information about the authentication issue, following the Pydantic error message standard, including which parameter is missing and where (e.g. body, query, path, etc). It will also hint if you are trying to send in a value that is not allowed in a certain parameter. - Verify your request against our API Reference, paying particular attention to the required headers for each endpoint.
- Go to Developer portal and double-check the Client Id of application you are using.
- If the issue persists, contact our support team at contact@leyr.io with:
- The
instance
ID from your error response - The endpoint you're trying to access
- A copy of your request headers (excluding sensitive data)
- The
Table of Contents