Oracle Integration · REST Adapter (Authorization Code grant)
OAuth: The token has already been consumed
This REST Adapter error in Oracle Integration means the connection could not refresh its access token, because no refresh token was received or the refresh token expired. Verify that the connection receives a refresh token. Make sure the scope includes offline_access.
VerifiedLast verified
01Error text
Failed retrieving access token using refresh token flow with error code [400]
The token has already been consumed.02Likely causes
- The refresh token was not received because the scope does not contain
offline_access. - The refresh token expired. This can happen when integrations run rarely, because the connection only refreshes tokens when an adapter call is made.
03How to fix it
- Verify that the connection receives a refresh token. Make sure the scope includes
offline_access. - Increase the refresh token expiration time in OCI Identity and Access Management for the confidential application used for OAuth.
iNotes
The default access token expiration is one hour and the default refresh token expiration is one week.
04Official documentation
→Related errors
- OCI Object Storage Search API returns 401 NotAuthenticatedThis 401 from the OCI Object Storage Search API through the Oracle Integration REST Adapter usually points to invalid credentials or an unsupported wildcard search. Make sure the file name being searched does not contain the character.
- RPST and OCI Service Invocation: NamespaceNotFoundA 404 NamespaceNotFound through the Oracle Integration REST Adapter with the RPST and OCI Service Invocation policy means the policy or dynamic group is not set correctly. Set the policy to perform the required operations.
- RPST and OCI Service Invocation: BucketAlreadyExistsA BucketAlreadyExists error through the Oracle Integration REST Adapter can mean the policy only lets the dynamic group read buckets, so creating a bucket fails. Create a policy that allows writing to the bucket.
Test every fix in a non-production environment before you apply it to production. See how entries are verified.
More for Oracle Integration work:Open Oracle Integration jobsOracle Integration rates and salaries