Class ExternalAccountAuthorizedUserCredentials.Builder (1.25.0)

public static class ExternalAccountAuthorizedUserCredentials.Builder extends GoogleCredentials.Builder

Inheritance

java.lang.Object > OAuth2Credentials.Builder > GoogleCredentials.Builder > ExternalAccountAuthorizedUserCredentials.Builder

Constructors

Builder()

protected Builder()

Builder(ExternalAccountAuthorizedUserCredentials credentials)

protected Builder(ExternalAccountAuthorizedUserCredentials credentials)
Parameter
Name Description
credentials ExternalAccountAuthorizedUserCredentials

Methods

build()

public ExternalAccountAuthorizedUserCredentials build()
Returns
Type Description
ExternalAccountAuthorizedUserCredentials
Overrides

setAccessToken(AccessToken accessToken)

public ExternalAccountAuthorizedUserCredentials.Builder setAccessToken(AccessToken accessToken)

Sets the optional access token.

Parameter
Name Description
accessToken AccessToken

the access token

Returns
Type Description
ExternalAccountAuthorizedUserCredentials.Builder

this Builder object

Overrides

setAudience(String audience)

public ExternalAccountAuthorizedUserCredentials.Builder setAudience(String audience)

Sets the optional audience, which is usually the fully specified resource name of the workforce pool provider.

Parameter
Name Description
audience String

the audience to set

Returns
Type Description
ExternalAccountAuthorizedUserCredentials.Builder

this Builder object

setClientId(String clientId)

public ExternalAccountAuthorizedUserCredentials.Builder setClientId(String clientId)

Sets the OAuth 2.0 client ID.

Parameter
Name Description
clientId String

the client ID

Returns
Type Description
ExternalAccountAuthorizedUserCredentials.Builder

this Builder object

setClientSecret(String clientSecret)

public ExternalAccountAuthorizedUserCredentials.Builder setClientSecret(String clientSecret)

Sets the OAuth 2.0 client secret.

Parameter
Name Description
clientSecret String

the client secret

Returns
Type Description
ExternalAccountAuthorizedUserCredentials.Builder

this Builder object

setHttpTransportFactory(HttpTransportFactory transportFactory)

public ExternalAccountAuthorizedUserCredentials.Builder setHttpTransportFactory(HttpTransportFactory transportFactory)

Sets the HTTP transport factory.

Parameter
Name Description
transportFactory HttpTransportFactory

the HttpTransportFactory to set

Returns
Type Description
ExternalAccountAuthorizedUserCredentials.Builder

this Builder object

setQuotaProjectId(String quotaProjectId)

public ExternalAccountAuthorizedUserCredentials.Builder setQuotaProjectId(String quotaProjectId)

Sets the optional project used for quota and billing purposes.

Parameter
Name Description
quotaProjectId String

the quota and billing project id to set

Returns
Type Description
ExternalAccountAuthorizedUserCredentials.Builder

this Builder object

Overrides

setRefreshToken(String refreshToken)

public ExternalAccountAuthorizedUserCredentials.Builder setRefreshToken(String refreshToken)

Sets the OAuth 2.0 refresh token.

Parameter
Name Description
refreshToken String

the refresh token

Returns
Type Description
ExternalAccountAuthorizedUserCredentials.Builder

this Builder object

setRevokeUrl(String revokeUrl)

public ExternalAccountAuthorizedUserCredentials.Builder setRevokeUrl(String revokeUrl)

Sets the token revocation endpoint.

Parameter
Name Description
revokeUrl String

the revoke url to set

Returns
Type Description
ExternalAccountAuthorizedUserCredentials.Builder

this Builder object

setTokenInfoUrl(String tokenInfoUrl)

public ExternalAccountAuthorizedUserCredentials.Builder setTokenInfoUrl(String tokenInfoUrl)

Sets the token introspection endpoint used to retrieve account related information.

Parameter
Name Description
tokenInfoUrl String

the token info url to set

Returns
Type Description
ExternalAccountAuthorizedUserCredentials.Builder

this Builder object

setTokenUrl(String tokenUrl)

public ExternalAccountAuthorizedUserCredentials.Builder setTokenUrl(String tokenUrl)

Sets the token exchange endpoint.

Parameter
Name Description
tokenUrl String

the token exchange url to set

Returns
Type Description
ExternalAccountAuthorizedUserCredentials.Builder

this Builder object

setUniverseDomain(String universeDomain)

public ExternalAccountAuthorizedUserCredentials.Builder setUniverseDomain(String universeDomain)

Sets the optional universe domain. The Google Default Universe is used when not provided.

Parameter
Name Description
universeDomain String

the universe domain to set

Returns
Type Description
ExternalAccountAuthorizedUserCredentials.Builder

this Builder object

Overrides