Class OAuth2RefreshToken

java.lang.Object
org.springframework.security.oauth2.core.AbstractOAuth2Token
org.springframework.security.oauth2.core.OAuth2RefreshToken
All Implemented Interfaces:
Serializable, OAuth2Token

public class OAuth2RefreshToken extends AbstractOAuth2Token
An implementation of an AbstractOAuth2Token representing an OAuth 2.0 Refresh Token.

A refresh token is a credential that represents an authorization granted by the resource owner to the client. It is used by the client to obtain a new access token when the current access token becomes invalid or expires, or to obtain additional access tokens with identical or narrower scope.

Since:
5.1
See Also:
  • Constructor Details

    • OAuth2RefreshToken

      public OAuth2RefreshToken(String tokenValue, Instant issuedAt)
      Constructs an OAuth2RefreshToken using the provided parameters.
      Parameters:
      tokenValue - the token value
      issuedAt - the time at which the token was issued
    • OAuth2RefreshToken

      public OAuth2RefreshToken(String tokenValue, Instant issuedAt, Instant expiresAt)
      Constructs an OAuth2RefreshToken using the provided parameters.
      Parameters:
      tokenValue - the token value
      issuedAt - the time at which the token was issued
      expiresAt - the time at which the token expires
      Since:
      5.5