If your API uses a token validation interceptor and returns a 401 Unauthorized status code, it indicates that the provided token is invalid. This may occur for one of the following reasons:
NOTEThe token validation interceptors are: OAuth, Access Token Validation, JWT Validation, Client ID Validation, CSRF Validation, Time Token Validation, and Digital Signature.
When providing credentials (such as an access token) in these interceptors, ensure that the value is used exactly as generated, without any leading or trailing spaces or line breaks. Any alteration to the original format may affect credential processing.
The response of the API call tells us which element carries the invalid token.
access_token (expired, revoked, incorrect, without access to the resource, not provided) the message will be:
Access Token in the request, identified by HEADER access_token, is invalid. Check docs.sensedia.comclient_id (expired, revoked, incorrect, without access to the resource, not provided) the message will be:
Client Id in the request, identified by HEADER client_id, is invalid. Check docs.sensedia.com%s in the request, identified by HEADER %s, is invalid. Check docs.sensedia.comIn the General trace logs, we can find a more detailed breakdown of the error, indicating whether the token is incorrect, expired, revoked or does not have access to the resource.
Access token in HEADER access_token HAS NOT BEEN FOUND (causes: is invalid, expired, or revoked); rejecting callAccess token in HEADER access_token DOES NOT HAVE ACCESS TO THIS RESOURCE; rejecting callWe use cookies to enhance your experience on our site. By continuing to browse, you agree to our use of cookies.Learn more