Forums

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

OAuth2 token stops working after 1 hour

Deleted user February 6, 2019

My app uses OAuth2 authentication to integrate with Jira Cloud. The oauth token works fine after for accessing the Jira API for an hour, after which the API starts returning a 401 error. Performing the Oauth2 flow again generates a new token, which works (again, for an hour). Do Altassian Oauth2 tokens expire? If so, how should they be refreshed? (I do not receive a refresh token during the oauth flow). 

1 answer

0 votes
Harry J.E Day (Last Day 21st July)
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 7, 2019

Hi Vishal are you including the `offline` scope in your oauth request? This should  cause it to return a refresh token you can use.

Deleted user February 8, 2019

Thanks Harry. I will try that. However, is there a way such that the oauth token does not expire? Based on this question, it seems that that the oauth token does not expire for a long time -- https://community.atlassian.com/t5/Jira-Core-questions/When-does-the-access-token-expire/qaq-p/928593

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events