Okta User Reactivation API Call Fails With Invalid Session Error
Last Updated:
Overview
An invalid session error occurs when attempting to reactivate a user via the Okta API because the request contains an invalid authorization header or an invalid API token. Resolve this issue by verifying the API key, generating a new API token, or updating the API client. Okta generates the following error when executing the POST /api/v1/users/<userId>/lifecycle/reactivate endpoint:
{ "errorCode": "E0000005", "errorSummary": "Invalid session", "errorLink": "E0000005", "errorId": "{ID}", "errorCauses": []}
Applies To
- Okta Identity Engine (OIE)
- Okta Classic Engine
- Application Programming Interface (API)
- Okta API
- User Lifecycle Management
Cause
The request contains an invalid authorization header or an invalid API token.
Review the invalid authorization header in the API client.
Solution
How is the invalid session error resolved?
Resolve the invalid session error by verifying the API key, generating a new API token in the Okta Admin Console, and updating the API client.
- Verify that the API key is valid.
- Create a new API token from the Okta Admin Console and use the new API token in the API client.
- Update the API client to the latest version.
NOTE: If the issue persists, open a case with Okta Support for further troubleshooting.
