Class OAuthSettings.Builder (0.44.0)

public static final class OAuthSettings.Builder extends GeneratedMessage.Builder<OAuthSettings.Builder> implements OAuthSettingsOrBuilder

Configuration for OAuth login&consent flow behavior as well as for OAuth Credentials.

Protobuf type google.cloud.iap.v1.OAuthSettings

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addAllProgrammaticClients(Iterable<String> values)

public OAuthSettings.Builder addAllProgrammaticClients(Iterable<String> values)

Optional. List of client ids allowed to use IAP programmatically.

repeated string programmatic_clients = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
values Iterable<String>

The programmaticClients to add.

Returns
Type Description
OAuthSettings.Builder

This builder for chaining.

addProgrammaticClients(String value)

public OAuthSettings.Builder addProgrammaticClients(String value)

Optional. List of client ids allowed to use IAP programmatically.

repeated string programmatic_clients = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The programmaticClients to add.

Returns
Type Description
OAuthSettings.Builder

This builder for chaining.

addProgrammaticClientsBytes(ByteString value)

public OAuthSettings.Builder addProgrammaticClientsBytes(ByteString value)

Optional. List of client ids allowed to use IAP programmatically.

repeated string programmatic_clients = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes of the programmaticClients to add.

Returns
Type Description
OAuthSettings.Builder

This builder for chaining.

build()

public OAuthSettings build()
Returns
Type Description
OAuthSettings

buildPartial()

public OAuthSettings buildPartial()
Returns
Type Description
OAuthSettings

clear()

public OAuthSettings.Builder clear()
Returns
Type Description
OAuthSettings.Builder
Overrides

clearClientId()

public OAuthSettings.Builder clearClientId()

Optional. OAuth 2.0 client ID used in the OAuth flow. This allows for client sharing. The risks of client sharing are outlined here: https://cloud.google.com/iap/docs/sharing-oauth-clients#risks.

.google.protobuf.StringValue client_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
OAuthSettings.Builder

clearClientSecret()

public OAuthSettings.Builder clearClientSecret()

Optional. Input only. OAuth secret paired with client ID.

.google.protobuf.StringValue client_secret = 4 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
OAuthSettings.Builder

clearClientSecretSha256()

public OAuthSettings.Builder clearClientSecretSha256()

Output only. OAuth secret SHA256 paired with client ID.

.google.protobuf.StringValue client_secret_sha256 = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
OAuthSettings.Builder

clearLoginHint()

public OAuthSettings.Builder clearLoginHint()

Domain hint to send as hd=? parameter in OAuth request flow. Enables redirect to primary IDP by skipping Google's login screen. https://developers.google.com/identity/protocols/OpenIDConnect#hd-param Note: IAP does not verify that the id token's hd claim matches this value since access behavior is managed by IAM policies.

.google.protobuf.StringValue login_hint = 2;

Returns
Type Description
OAuthSettings.Builder

clearProgrammaticClients()

public OAuthSettings.Builder clearProgrammaticClients()

Optional. List of client ids allowed to use IAP programmatically.

repeated string programmatic_clients = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
OAuthSettings.Builder

This builder for chaining.

getClientId()

public StringValue getClientId()

Optional. OAuth 2.0 client ID used in the OAuth flow. This allows for client sharing. The risks of client sharing are outlined here: https://cloud.google.com/iap/docs/sharing-oauth-clients#risks.

.google.protobuf.StringValue client_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
StringValue

The clientId.

getClientIdBuilder()

public StringValue.Builder getClientIdBuilder()

Optional. OAuth 2.0 client ID used in the OAuth flow. This allows for client sharing. The risks of client sharing are outlined here: https://cloud.google.com/iap/docs/sharing-oauth-clients#risks.

.google.protobuf.StringValue client_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Builder

getClientIdOrBuilder()

public StringValueOrBuilder getClientIdOrBuilder()

Optional. OAuth 2.0 client ID used in the OAuth flow. This allows for client sharing. The risks of client sharing are outlined here: https://cloud.google.com/iap/docs/sharing-oauth-clients#risks.

.google.protobuf.StringValue client_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
StringValueOrBuilder

getClientSecret()

public StringValue getClientSecret()

Optional. Input only. OAuth secret paired with client ID.

.google.protobuf.StringValue client_secret = 4 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
StringValue

The clientSecret.

getClientSecretBuilder()

public StringValue.Builder getClientSecretBuilder()

Optional. Input only. OAuth secret paired with client ID.

.google.protobuf.StringValue client_secret = 4 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Builder

getClientSecretOrBuilder()

public StringValueOrBuilder getClientSecretOrBuilder()

Optional. Input only. OAuth secret paired with client ID.

.google.protobuf.StringValue client_secret = 4 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
StringValueOrBuilder

getClientSecretSha256()

public StringValue getClientSecretSha256()

Output only. OAuth secret SHA256 paired with client ID.

.google.protobuf.StringValue client_secret_sha256 = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
StringValue

The clientSecretSha256.

getClientSecretSha256Builder()

public StringValue.Builder getClientSecretSha256Builder()

Output only. OAuth secret SHA256 paired with client ID.

.google.protobuf.StringValue client_secret_sha256 = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Builder

getClientSecretSha256OrBuilder()

public StringValueOrBuilder getClientSecretSha256OrBuilder()

Output only. OAuth secret SHA256 paired with client ID.

.google.protobuf.StringValue client_secret_sha256 = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
StringValueOrBuilder

getDefaultInstanceForType()

public OAuthSettings getDefaultInstanceForType()
Returns
Type Description
OAuthSettings

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getLoginHint()

public StringValue getLoginHint()

Domain hint to send as hd=? parameter in OAuth request flow. Enables redirect to primary IDP by skipping Google's login screen. https://developers.google.com/identity/protocols/OpenIDConnect#hd-param Note: IAP does not verify that the id token's hd claim matches this value since access behavior is managed by IAM policies.

.google.protobuf.StringValue login_hint = 2;

Returns
Type Description
StringValue

The loginHint.

getLoginHintBuilder()

public StringValue.Builder getLoginHintBuilder()

Domain hint to send as hd=? parameter in OAuth request flow. Enables redirect to primary IDP by skipping Google's login screen. https://developers.google.com/identity/protocols/OpenIDConnect#hd-param Note: IAP does not verify that the id token's hd claim matches this value since access behavior is managed by IAM policies.

.google.protobuf.StringValue login_hint = 2;

Returns
Type Description
Builder

getLoginHintOrBuilder()

public StringValueOrBuilder getLoginHintOrBuilder()

Domain hint to send as hd=? parameter in OAuth request flow. Enables redirect to primary IDP by skipping Google's login screen. https://developers.google.com/identity/protocols/OpenIDConnect#hd-param Note: IAP does not verify that the id token's hd claim matches this value since access behavior is managed by IAM policies.

.google.protobuf.StringValue login_hint = 2;

Returns
Type Description
StringValueOrBuilder

getProgrammaticClients(int index)

public String getProgrammaticClients(int index)

Optional. List of client ids allowed to use IAP programmatically.

repeated string programmatic_clients = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
String

The programmaticClients at the given index.

getProgrammaticClientsBytes(int index)

public ByteString getProgrammaticClientsBytes(int index)

Optional. List of client ids allowed to use IAP programmatically.

repeated string programmatic_clients = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int

The index of the value to return.

Returns
Type Description
ByteString

The bytes of the programmaticClients at the given index.

getProgrammaticClientsCount()

public int getProgrammaticClientsCount()

Optional. List of client ids allowed to use IAP programmatically.

repeated string programmatic_clients = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The count of programmaticClients.

getProgrammaticClientsList()

public ProtocolStringList getProgrammaticClientsList()

Optional. List of client ids allowed to use IAP programmatically.

repeated string programmatic_clients = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ProtocolStringList

A list containing the programmaticClients.

hasClientId()

public boolean hasClientId()

Optional. OAuth 2.0 client ID used in the OAuth flow. This allows for client sharing. The risks of client sharing are outlined here: https://cloud.google.com/iap/docs/sharing-oauth-clients#risks.

.google.protobuf.StringValue client_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the clientId field is set.

hasClientSecret()

public boolean hasClientSecret()

Optional. Input only. OAuth secret paired with client ID.

.google.protobuf.StringValue client_secret = 4 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the clientSecret field is set.

hasClientSecretSha256()

public boolean hasClientSecretSha256()

Output only. OAuth secret SHA256 paired with client ID.

.google.protobuf.StringValue client_secret_sha256 = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the clientSecretSha256 field is set.

hasLoginHint()

public boolean hasLoginHint()

Domain hint to send as hd=? parameter in OAuth request flow. Enables redirect to primary IDP by skipping Google's login screen. https://developers.google.com/identity/protocols/OpenIDConnect#hd-param Note: IAP does not verify that the id token's hd claim matches this value since access behavior is managed by IAM policies.

.google.protobuf.StringValue login_hint = 2;

Returns
Type Description
boolean

Whether the loginHint field is set.

internalGetFieldAccessorTable()

protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeClientId(StringValue value)

public OAuthSettings.Builder mergeClientId(StringValue value)

Optional. OAuth 2.0 client ID used in the OAuth flow. This allows for client sharing. The risks of client sharing are outlined here: https://cloud.google.com/iap/docs/sharing-oauth-clients#risks.

.google.protobuf.StringValue client_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value StringValue
Returns
Type Description
OAuthSettings.Builder

mergeClientSecret(StringValue value)

public OAuthSettings.Builder mergeClientSecret(StringValue value)

Optional. Input only. OAuth secret paired with client ID.

.google.protobuf.StringValue client_secret = 4 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value StringValue
Returns
Type Description
OAuthSettings.Builder

mergeClientSecretSha256(StringValue value)

public OAuthSettings.Builder mergeClientSecretSha256(StringValue value)

Output only. OAuth secret SHA256 paired with client ID.

.google.protobuf.StringValue client_secret_sha256 = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value StringValue
Returns
Type Description
OAuthSettings.Builder

mergeFrom(OAuthSettings other)

public OAuthSettings.Builder mergeFrom(OAuthSettings other)
Parameter
Name Description
other OAuthSettings
Returns
Type Description
OAuthSettings.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public OAuthSettings.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
OAuthSettings.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public OAuthSettings.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
OAuthSettings.Builder
Overrides

mergeLoginHint(StringValue value)

public OAuthSettings.Builder mergeLoginHint(StringValue value)

Domain hint to send as hd=? parameter in OAuth request flow. Enables redirect to primary IDP by skipping Google's login screen. https://developers.google.com/identity/protocols/OpenIDConnect#hd-param Note: IAP does not verify that the id token's hd claim matches this value since access behavior is managed by IAM policies.

.google.protobuf.StringValue login_hint = 2;

Parameter
Name Description
value StringValue
Returns
Type Description
OAuthSettings.Builder

setClientId(StringValue value)

public OAuthSettings.Builder setClientId(StringValue value)

Optional. OAuth 2.0 client ID used in the OAuth flow. This allows for client sharing. The risks of client sharing are outlined here: https://cloud.google.com/iap/docs/sharing-oauth-clients#risks.

.google.protobuf.StringValue client_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value StringValue
Returns
Type Description
OAuthSettings.Builder

setClientId(StringValue.Builder builderForValue)

public OAuthSettings.Builder setClientId(StringValue.Builder builderForValue)

Optional. OAuth 2.0 client ID used in the OAuth flow. This allows for client sharing. The risks of client sharing are outlined here: https://cloud.google.com/iap/docs/sharing-oauth-clients#risks.

.google.protobuf.StringValue client_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
OAuthSettings.Builder

setClientSecret(StringValue value)

public OAuthSettings.Builder setClientSecret(StringValue value)

Optional. Input only. OAuth secret paired with client ID.

.google.protobuf.StringValue client_secret = 4 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value StringValue
Returns
Type Description
OAuthSettings.Builder

setClientSecret(StringValue.Builder builderForValue)

public OAuthSettings.Builder setClientSecret(StringValue.Builder builderForValue)

Optional. Input only. OAuth secret paired with client ID.

.google.protobuf.StringValue client_secret = 4 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
OAuthSettings.Builder

setClientSecretSha256(StringValue value)

public OAuthSettings.Builder setClientSecretSha256(StringValue value)

Output only. OAuth secret SHA256 paired with client ID.

.google.protobuf.StringValue client_secret_sha256 = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value StringValue
Returns
Type Description
OAuthSettings.Builder

setClientSecretSha256(StringValue.Builder builderForValue)

public OAuthSettings.Builder setClientSecretSha256(StringValue.Builder builderForValue)

Output only. OAuth secret SHA256 paired with client ID.

.google.protobuf.StringValue client_secret_sha256 = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
OAuthSettings.Builder

setLoginHint(StringValue value)

public OAuthSettings.Builder setLoginHint(StringValue value)

Domain hint to send as hd=? parameter in OAuth request flow. Enables redirect to primary IDP by skipping Google's login screen. https://developers.google.com/identity/protocols/OpenIDConnect#hd-param Note: IAP does not verify that the id token's hd claim matches this value since access behavior is managed by IAM policies.

.google.protobuf.StringValue login_hint = 2;

Parameter
Name Description
value StringValue
Returns
Type Description
OAuthSettings.Builder

setLoginHint(StringValue.Builder builderForValue)

public OAuthSettings.Builder setLoginHint(StringValue.Builder builderForValue)

Domain hint to send as hd=? parameter in OAuth request flow. Enables redirect to primary IDP by skipping Google's login screen. https://developers.google.com/identity/protocols/OpenIDConnect#hd-param Note: IAP does not verify that the id token's hd claim matches this value since access behavior is managed by IAM policies.

.google.protobuf.StringValue login_hint = 2;

Parameter
Name Description
builderForValue Builder
Returns
Type Description
OAuthSettings.Builder

setProgrammaticClients(int index, String value)

public OAuthSettings.Builder setProgrammaticClients(int index, String value)

Optional. List of client ids allowed to use IAP programmatically.

repeated string programmatic_clients = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
index int

The index to set the value at.

value String

The programmaticClients to set.

Returns
Type Description
OAuthSettings.Builder

This builder for chaining.