java.lang.Object
org.springframework.security.oauth2.client.userinfo.OAuth2UserRequest
org.springframework.security.oauth2.client.oidc.userinfo.OidcUserRequest

public class OidcUserRequest extends OAuth2UserRequest
Represents a request the OidcUserService uses when initiating a request to the UserInfo Endpoint.
Since:
5.0
See Also:
  • Constructor Details

    • OidcUserRequest

      public OidcUserRequest(ClientRegistration clientRegistration, OAuth2AccessToken accessToken, OidcIdToken idToken)
      Constructs an OidcUserRequest using the provided parameters.
      Parameters:
      clientRegistration - the client registration
      accessToken - the access token credential
      idToken - the ID Token
    • OidcUserRequest

      public OidcUserRequest(ClientRegistration clientRegistration, OAuth2AccessToken accessToken, OidcIdToken idToken, Map<String,Object> additionalParameters)
      Constructs an OidcUserRequest using the provided parameters.
      Parameters:
      clientRegistration - the client registration
      accessToken - the access token credential
      idToken - the ID Token
      additionalParameters - the additional parameters, may be empty
      Since:
      5.1
  • Method Details

    • getIdToken

      public OidcIdToken getIdToken()
      Returns the ID Token containing claims about the user.
      Returns:
      the OidcIdToken containing claims about the user.