Auto login to OKTA when refreshing the token

Hi guys, we have implemented secutiry in our api with okta using a token and works fine but when the token expires it won’t refresh the token automatically (even though Auto-refresh token is checked) so we have to enter to the Account(REST OAuth2 Account) and click authorize to get a new one but it opens a pop up window asking to put your okta credentials, so we always have to do it manually because we don’t want to be spreading the credentials nor have to be refreshing the tokens manually.
Is there a way to make the Account to automatically log in to okta and to refresh the token without someone having to get a new token every hour and a half?
note.refresh button in Account window won’t work as it displays “error: access token refresh failed”
thanks for reading.