-
-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
Description
Question
I'm using a Salesforce provider and although there is no expiry on the saved token, the session is timing out:
{"message":"Session expired or invalid","errorCode":"INVALID_SESSION_ID"}
So I am looking at the Auth::$plugin->getTokens()->refreshToken() method to get a new access token. However this doesn't seem to make a call to the provider to get a new token and instead seems to just update the existing token record
public function refreshToken(Token $token, OAuth1Token|OAuth2Token $accessToken): bool
{
$token->accessToken = $accessToken->getToken();
$token->expires = $accessToken->getExpires();
if ($accessToken->getRefreshToken()) {
$token->refreshToken = $accessToken->getRefreshToken();
}
// Ensure that we update the token's access token with new values for the next request
$token->setToken($accessToken);
return $this->saveToken($token);
}Am I missing something here?
Additional context
No response
Reactions are currently unavailable