Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Authorization code for OAUTH 2.0 gets invalid

Ravi Singh
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
September 8, 2022

Hi Team,

I am trying to use Ouath to authenticate API calls. To get access token I use authorization code received by https://developer.atlassian.com/cloud/confluence/oauth-2-3lo-apps/#1--direct-the-user-to-the-authorization-url-to-get-an-authorization-code.

But after some time I start getting Unauthorized access and for authorization code as "

authorization_code is invalid". 
Can you please help me with how can I use one authorization code  for lifetime so that I just need to refresh access_token. Or is there way to get authorization code via code.

1 answer

0 votes
marc -Collabello--Phase Locked-
Community Champion
September 9, 2022

The tokens will expire after some time, and you must go through the token flow again.  However I believe the expiry is 1 year.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD Trial
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events