Class OAuth2UpdateConfig

java.lang.Object
com.google.genai.gaos.models.credentials.OAuth2UpdateConfig
All Implemented Interfaces:
CredentialUpdate

public class OAuth2UpdateConfig extends Object implements CredentialUpdate
OAuth2UpdateConfig

Configuration for updating OAuth2 credentials.

  • Constructor Details

    • OAuth2UpdateConfig

      public OAuth2UpdateConfig(@Nullable String clientId, @Nullable String clientSecret, @Nullable String refreshToken, @Nullable List<String> scopes, @Nullable String tokenUrl)
    • OAuth2UpdateConfig

      public OAuth2UpdateConfig()
  • Method Details

    • clientId

      public Optional<String> clientId()
      Optional. OAuth2 client ID.
    • clientSecret

      public Optional<String> clientSecret()
      Optional. Input only. OAuth2 client secret.

      Write-only; never returned in responses.

    • refreshToken

      public Optional<String> refreshToken()
      Optional. Input only. OAuth2 refresh token.

      Write-only; never returned in responses.

    • scopes

      public Optional<List<String>> scopes()
      Optional. List of OAuth2 scopes.
    • tokenUrl

      public Optional<String> tokenUrl()
      Optional. OAuth2 token endpoint URL for refreshing access tokens.
    • type

      public String type()
      Specified by:
      type in interface CredentialUpdate
    • builder

      public static OAuth2UpdateConfig.Builder builder()
    • withClientId

      public OAuth2UpdateConfig withClientId(@Nullable String clientId)
      Optional. OAuth2 client ID.
    • withClientSecret

      public OAuth2UpdateConfig withClientSecret(@Nullable String clientSecret)
      Optional. Input only. OAuth2 client secret.

      Write-only; never returned in responses.

    • withRefreshToken

      public OAuth2UpdateConfig withRefreshToken(@Nullable String refreshToken)
      Optional. Input only. OAuth2 refresh token.

      Write-only; never returned in responses.

    • withScopes

      public OAuth2UpdateConfig withScopes(@Nullable List<String> scopes)
      Optional. List of OAuth2 scopes.
    • withTokenUrl

      public OAuth2UpdateConfig withTokenUrl(@Nullable String tokenUrl)
      Optional. OAuth2 token endpoint URL for refreshing access tokens.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object