Can refresh tokens expire for GitLab OAuth?

Hello GitLab,

I am currently using the GitLabs OAuth flows to obtain an access token and refresh tokens to perform various GIT operations by using the Gitlab’s REST APIs. I am aware that the Gitlab access tokens expire every 2 hours, but one thing that I have observed is that after I try to perform the token refresh flow to obtain a new access and refresh token pairs from Gitlab, it seems that the refresh token no longer works and throws a invalid_grant error.

Can anyone tell me if there is a limit or certain fixed duration for which the refresh token can be valid and be used to obtain a new access token?
Can anyone point me to any resources specifying this expiration time for the refresh tokens for Gitlab?

1 Like