java.lang.Object
africa.absa.inception.oauth2.server.authorization.controller.GrantRequest
Direct Known Subclasses:
RefreshAccessTokenGrantRequest, ResourceOwnerPasswordCredentialsGrantRequest

public abstract class GrantRequest extends Object
The GrantRequest class provides the base class that all OAuth2 grant request classes should be derived from.
Author:
Marcus Portmann
  • Field Details

    • CLIENT_ID_PARAMETER

      public static final String CLIENT_ID_PARAMETER
      The name of the client ID parameter.

      This parameter is REQUIRED if client authentication is enabled.

      See Also:
    • CLIENT_SECRET_PARAMETER

      public static final String CLIENT_SECRET_PARAMETER
      The name of the client secret parameter.

      This parameter is REQUIRED if client authentication is enabled.

      See Also:
    • GRANT_TYPE_PARAMETER

      public static final String GRANT_TYPE_PARAMETER
      The name of the grant type parameter.

      This parameter is REQUIRED.

      See Also:
    • SCOPE_PARAMETER

      public static final String SCOPE_PARAMETER
      The name of the parameter providing the requested access token scope.

      See Access Token Scope

      This parameter is OPTIONAL.

      See Also:
    • STATE_PARAMETER

      public static final String STATE_PARAMETER
      The name of the state parameter.

      This parameter is OPTIONAL.

      See Also:
  • Constructor Details

    • GrantRequest

      public GrantRequest(Map<String,String> parameters)
      Constructs a new GrantRequest.
      Parameters:
      parameters - the request parameters
  • Method Details

    • getClientId

      public String getClientId()
      Returns the client identifier issued to the client.
      Returns:
      the client identifier issued to the client
    • getClientSecret

      public String getClientSecret()
      Returns the client secret.
      Returns:
      the client secret
    • getGrantType

      public String getGrantType()
      Returns the grant type.
      Returns:
      the grant type
    • getScope

      public String getScope()
      Returns the requested scope(s) for the access request.
      Returns:
      the requested scope(s) for the access request
    • getState

      public String getState()
      Returns the state received from the client.
      Returns:
      the state received from the client