Package io.vertx.ext.auth.oauth2

## Class OAuth2AuthorizationURL

- java.lang.Object
- - io.vertx.ext.auth.oauth2.OAuth2AuthorizationURL

-     public class OAuth2AuthorizationURL
      extends Object

  TypeSafe DataObject for passing needed parameters for `OAuth2Auth.authorizeURL(OAuth2AuthorizationURL)`
  Author:
    Lazar Bulic

- - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `OAuth2AuthorizationURL()` | Default constructor
    `OAuth2AuthorizationURL​(JsonObject json)` | Constructor to create an options from JSON
    `OAuth2AuthorizationURL​(OAuth2AuthorizationURL other)` | Constructor to create an options from an existing options

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `OAuth2AuthorizationURL` | `addScope​(String scope)` | Add a scope
    `Map<String,​String>` | `getAdditionalParameters()` | Get the additional parameters
    `String` | `getCodeChallenge()` | PKCE code challenge
    `String` | `getCodeChallengeMethod()` | PKCE code challenge method
    `String` | `getLoginHint()` | Hint on login name for IdP UI
    `String` | `getPrompt()` | Hint on kind of IdP prompt
    `String` | `getRedirectUri()` | Get the redirect URI
    `List<String>` | `getScopes()` | Get the scopes
    `String` | `getState()` | Get the state
    `OAuth2AuthorizationURL` | `putAdditionalParameter​(String key, String value)` | Add an additional parameter
    `OAuth2AuthorizationURL` | `setAdditionalParameters​(Map<String,​String> additionalParameters)` | Set the additional parameters
    `OAuth2AuthorizationURL` | `setCodeChallenge​(String codeChallenge)` | PKCE code challenge
    `OAuth2AuthorizationURL` | `setCodeChallengeMethod​(String codeChallengeMethod)` | PKCE code challenge method
    `OAuth2AuthorizationURL` | `setLoginHint​(String loginHint)` | Hint on login name for IdP UI
    `OAuth2AuthorizationURL` | `setPrompt​(String prompt)` | Hint on kind of IdP prompt
    `OAuth2AuthorizationURL` | `setRedirectUri​(String redirectUri)` | Set the redirect URI
    `OAuth2AuthorizationURL` | `setScopes​(List<String> scopes)` | Set the scopes
    `OAuth2AuthorizationURL` | `setState​(String state)` | Set the state
    `JsonObject` | `toJson()` |
    `String` | `toString()` |

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### OAuth2AuthorizationURL

          public OAuth2AuthorizationURL()

      Default constructor

    - #### OAuth2AuthorizationURL

          public OAuth2AuthorizationURL​(JsonObject json)

      Constructor to create an options from JSON
      Parameters:
        `json` - the JSON

    - #### OAuth2AuthorizationURL

          public OAuth2AuthorizationURL​(OAuth2AuthorizationURL other)

      Constructor to create an options from an existing options
      Parameters:
        `other` - the existing one to clone

  - ### Method Detail

    - #### getRedirectUri

          public String getRedirectUri()

      Get the redirect URI
      Returns:
        the redirectUri

    - #### setRedirectUri

          public OAuth2AuthorizationURL setRedirectUri​(String redirectUri)

      Set the redirect URI
      Parameters:
        `redirectUri` - the redirectUri to set
      Returns:
        self

    - #### getScopes

          public List<String> getScopes()

      Get the scopes
      Returns:
        the scopes

    - #### setScopes

          public OAuth2AuthorizationURL setScopes​(List<String> scopes)

      Set the scopes
      Parameters:
        `scopes` - the scopes to set
      Returns:
        self

    - #### addScope

          public OAuth2AuthorizationURL addScope​(String scope)

      Add a scope
      Parameters:
        `scope` - the scope to add
      Returns:
        self

    - #### getState

          public String getState()

      Get the state
      Returns:
        the state

    - #### setState

          public OAuth2AuthorizationURL setState​(String state)

      Set the state
      Parameters:
        `state` - the state to set
      Returns:
        self

    - #### getCodeChallenge

          public String getCodeChallenge()

      PKCE code challenge

    - #### setCodeChallenge

          public OAuth2AuthorizationURL setCodeChallenge​(String codeChallenge)

      PKCE code challenge

    - #### getCodeChallengeMethod

          public String getCodeChallengeMethod()

      PKCE code challenge method

    - #### setCodeChallengeMethod

          public OAuth2AuthorizationURL setCodeChallengeMethod​(String codeChallengeMethod)

      PKCE code challenge method

    - #### getPrompt

          public String getPrompt()

      Hint on kind of IdP prompt

    - #### setPrompt

          public OAuth2AuthorizationURL setPrompt​(String prompt)

      Hint on kind of IdP prompt

    - #### getLoginHint

          public String getLoginHint()

      Hint on login name for IdP UI

    - #### setLoginHint

          public OAuth2AuthorizationURL setLoginHint​(String loginHint)

      Hint on login name for IdP UI

    - #### getAdditionalParameters

          public Map<String,​String> getAdditionalParameters()

      Get the additional parameters
      Returns:
        the additionalParameters

    - #### setAdditionalParameters

          public OAuth2AuthorizationURL setAdditionalParameters​(Map<String,​String> additionalParameters)

      Set the additional parameters
      Parameters:
        `additionalParameters` - the additionalParameters to set. Both key and value should be in final format that is expected by the provider. Example: "ui_locales" -> "fr-CA fr en"
      Returns:
        self

    - #### putAdditionalParameter

          public OAuth2AuthorizationURL putAdditionalParameter​(String key,
                                                               String value)

      Add an additional parameter
      Parameters:
        `key` - the key of the parameter. Should be in final format that is expected by the provider. Example: "ui_locales"
        `value` - the value of the parameter. Should be in final format that is expected by the provider. Example: "fr-CA fr en"
      Returns:
        self

    - #### toJson

          public JsonObject toJson()

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`