Class IdentityAwareProxyOAuthServiceClient (0.9.0)

GitHub RepositoryProduct Reference

Service Description: API to programmatically create, list and retrieve Identity Aware Proxy (IAP) OAuth brands; and create, retrieve, delete and reset-secret of IAP OAuth clients.

This class provides the ability to make remote calls to the backing service through method calls that map to API methods. Sample code to get started:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   ListBrandsRequest request =
       ListBrandsRequest.newBuilder().setParent("parent-995424086").build();
   ListBrandsResponse response = identityAwareProxyOAuthServiceClient.listBrands(request);
 }
 

Note: close() needs to be called on the IdentityAwareProxyOAuthServiceClient object to clean up resources such as threads. In the example above, try-with-resources is used, which automatically calls close().

Methods
Method Description Method Variants

ListBrands

Lists the existing brands for the project.

Request object method variants only take one parameter, a request object, which must be constructed before the call.

  • listBrands(ListBrandsRequest request)

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

  • listBrandsCallable()

CreateBrand

Constructs a new OAuth brand for the project if one does not exist. The created brand is "internal only", meaning that OAuth clients created under it only accept requests from users who belong to the same Google Workspace organization as the project. The brand is created in an un-reviewed status. NOTE: The "internal only" status can be manually changed in the Google Cloud Console. Requires that a brand does not already exist for the project, and that the specified support email is owned by the caller.

Request object method variants only take one parameter, a request object, which must be constructed before the call.

  • createBrand(CreateBrandRequest request)

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

  • createBrandCallable()

GetBrand

Retrieves the OAuth brand of the project.

Request object method variants only take one parameter, a request object, which must be constructed before the call.

  • getBrand(GetBrandRequest request)

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

  • getBrandCallable()

CreateIdentityAwareProxyClient

Creates an Identity Aware Proxy (IAP) OAuth client. The client is owned by IAP. Requires that the brand for the project exists and that it is set for internal-only use.

Request object method variants only take one parameter, a request object, which must be constructed before the call.

  • createIdentityAwareProxyClient(CreateIdentityAwareProxyClientRequest request)

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

  • createIdentityAwareProxyClientCallable()

ListIdentityAwareProxyClients

Lists the existing clients for the brand.

Request object method variants only take one parameter, a request object, which must be constructed before the call.

  • listIdentityAwareProxyClients(ListIdentityAwareProxyClientsRequest request)

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

  • listIdentityAwareProxyClientsPagedCallable()

  • listIdentityAwareProxyClientsCallable()

GetIdentityAwareProxyClient

Retrieves an Identity Aware Proxy (IAP) OAuth client. Requires that the client is owned by IAP.

Request object method variants only take one parameter, a request object, which must be constructed before the call.

  • getIdentityAwareProxyClient(GetIdentityAwareProxyClientRequest request)

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

  • getIdentityAwareProxyClientCallable()

ResetIdentityAwareProxyClientSecret

Resets an Identity Aware Proxy (IAP) OAuth client secret. Useful if the secret was compromised. Requires that the client is owned by IAP.

Request object method variants only take one parameter, a request object, which must be constructed before the call.

  • resetIdentityAwareProxyClientSecret(ResetIdentityAwareProxyClientSecretRequest request)

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

  • resetIdentityAwareProxyClientSecretCallable()

DeleteIdentityAwareProxyClient

Deletes an Identity Aware Proxy (IAP) OAuth client. Useful for removing obsolete clients, managing the number of clients in a given project, and cleaning up after tests. Requires that the client is owned by IAP.

Request object method variants only take one parameter, a request object, which must be constructed before the call.

  • deleteIdentityAwareProxyClient(DeleteIdentityAwareProxyClientRequest request)

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

  • deleteIdentityAwareProxyClientCallable()

See the individual methods for example code.

Many parameters require resource names to be formatted in a particular way. To assist with these names, this class includes a format method for each type of name, and additionally a parse method to extract the individual identifiers contained within names that are returned.

This class can be customized by passing in a custom instance of IdentityAwareProxyOAuthServiceSettings to create(). For example:

To customize credentials:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 IdentityAwareProxyOAuthServiceSettings identityAwareProxyOAuthServiceSettings =
     IdentityAwareProxyOAuthServiceSettings.newBuilder()
         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
         .build();
 IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create(identityAwareProxyOAuthServiceSettings);
 

To customize the endpoint:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 IdentityAwareProxyOAuthServiceSettings identityAwareProxyOAuthServiceSettings =
     IdentityAwareProxyOAuthServiceSettings.newBuilder().setEndpoint(myEndpoint).build();
 IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create(identityAwareProxyOAuthServiceSettings);
 

To use REST (HTTP1.1/JSON) transport (instead of gRPC) for sending and receiving requests over the wire:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 IdentityAwareProxyOAuthServiceSettings identityAwareProxyOAuthServiceSettings =
     IdentityAwareProxyOAuthServiceSettings.newHttpJsonBuilder().build();
 IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create(identityAwareProxyOAuthServiceSettings);
 

Please refer to the GitHub repository's samples for more quickstart code snippets.

Inheritance

java.lang.Object > IdentityAwareProxyOAuthServiceClient

Static Methods

create()

public static final IdentityAwareProxyOAuthServiceClient create()

Constructs an instance of IdentityAwareProxyOAuthServiceClient with default settings.

Returns
Type Description
IdentityAwareProxyOAuthServiceClient
Exceptions
Type Description
IOException

create(IdentityAwareProxyOAuthServiceSettings settings)

public static final IdentityAwareProxyOAuthServiceClient create(IdentityAwareProxyOAuthServiceSettings settings)

Constructs an instance of IdentityAwareProxyOAuthServiceClient, using the given settings. The channels are created based on the settings passed in, or defaults for any settings that are not set.

Parameter
Name Description
settings IdentityAwareProxyOAuthServiceSettings
Returns
Type Description
IdentityAwareProxyOAuthServiceClient
Exceptions
Type Description
IOException

create(IdentityAwareProxyOAuthServiceStub stub)

public static final IdentityAwareProxyOAuthServiceClient create(IdentityAwareProxyOAuthServiceStub stub)

Constructs an instance of IdentityAwareProxyOAuthServiceClient, using the given stub for making calls. This is for advanced usage - prefer using create(IdentityAwareProxyOAuthServiceSettings).

Parameter
Name Description
stub IdentityAwareProxyOAuthServiceStub
Returns
Type Description
IdentityAwareProxyOAuthServiceClient

Constructors

IdentityAwareProxyOAuthServiceClient(IdentityAwareProxyOAuthServiceSettings settings)

protected IdentityAwareProxyOAuthServiceClient(IdentityAwareProxyOAuthServiceSettings settings)

Constructs an instance of IdentityAwareProxyOAuthServiceClient, using the given settings. This is protected so that it is easy to make a subclass, but otherwise, the static factory methods should be preferred.

Parameter
Name Description
settings IdentityAwareProxyOAuthServiceSettings

IdentityAwareProxyOAuthServiceClient(IdentityAwareProxyOAuthServiceStub stub)

protected IdentityAwareProxyOAuthServiceClient(IdentityAwareProxyOAuthServiceStub stub)
Parameter
Name Description
stub IdentityAwareProxyOAuthServiceStub

Methods

awaitTermination(long duration, TimeUnit unit)

public boolean awaitTermination(long duration, TimeUnit unit)
Parameters
Name Description
duration long
unit TimeUnit
Returns
Type Description
boolean
Exceptions
Type Description
InterruptedException

close()

public final void close()

createBrand(CreateBrandRequest request)

public final Brand createBrand(CreateBrandRequest request)

Constructs a new OAuth brand for the project if one does not exist. The created brand is "internal only", meaning that OAuth clients created under it only accept requests from users who belong to the same Google Workspace organization as the project. The brand is created in an un-reviewed status. NOTE: The "internal only" status can be manually changed in the Google Cloud Console. Requires that a brand does not already exist for the project, and that the specified support email is owned by the caller.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   CreateBrandRequest request =
       CreateBrandRequest.newBuilder()
           .setParent("parent-995424086")
           .setBrand(Brand.newBuilder().build())
           .build();
   Brand response = identityAwareProxyOAuthServiceClient.createBrand(request);
 }
 
Parameter
Name Description
request CreateBrandRequest

The request object containing all of the parameters for the API call.

Returns
Type Description
Brand

createBrandCallable()

public final UnaryCallable<CreateBrandRequest,Brand> createBrandCallable()

Constructs a new OAuth brand for the project if one does not exist. The created brand is "internal only", meaning that OAuth clients created under it only accept requests from users who belong to the same Google Workspace organization as the project. The brand is created in an un-reviewed status. NOTE: The "internal only" status can be manually changed in the Google Cloud Console. Requires that a brand does not already exist for the project, and that the specified support email is owned by the caller.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   CreateBrandRequest request =
       CreateBrandRequest.newBuilder()
           .setParent("parent-995424086")
           .setBrand(Brand.newBuilder().build())
           .build();
   ApiFuture<Brand> future =
       identityAwareProxyOAuthServiceClient.createBrandCallable().futureCall(request);
   // Do something.
   Brand response = future.get();
 }
 
Returns
Type Description
UnaryCallable<CreateBrandRequest,Brand>

createIdentityAwareProxyClient(CreateIdentityAwareProxyClientRequest request)

public final IdentityAwareProxyClient createIdentityAwareProxyClient(CreateIdentityAwareProxyClientRequest request)

Creates an Identity Aware Proxy (IAP) OAuth client. The client is owned by IAP. Requires that the brand for the project exists and that it is set for internal-only use.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   CreateIdentityAwareProxyClientRequest request =
       CreateIdentityAwareProxyClientRequest.newBuilder()
           .setParent("parent-995424086")
           .setIdentityAwareProxyClient(IdentityAwareProxyClient.newBuilder().build())
           .build();
   IdentityAwareProxyClient response =
       identityAwareProxyOAuthServiceClient.createIdentityAwareProxyClient(request);
 }
 
Parameter
Name Description
request CreateIdentityAwareProxyClientRequest

The request object containing all of the parameters for the API call.

Returns
Type Description
IdentityAwareProxyClient

createIdentityAwareProxyClientCallable()

public final UnaryCallable<CreateIdentityAwareProxyClientRequest,IdentityAwareProxyClient> createIdentityAwareProxyClientCallable()

Creates an Identity Aware Proxy (IAP) OAuth client. The client is owned by IAP. Requires that the brand for the project exists and that it is set for internal-only use.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   CreateIdentityAwareProxyClientRequest request =
       CreateIdentityAwareProxyClientRequest.newBuilder()
           .setParent("parent-995424086")
           .setIdentityAwareProxyClient(IdentityAwareProxyClient.newBuilder().build())
           .build();
   ApiFuture<IdentityAwareProxyClient> future =
       identityAwareProxyOAuthServiceClient
           .createIdentityAwareProxyClientCallable()
           .futureCall(request);
   // Do something.
   IdentityAwareProxyClient response = future.get();
 }
 
Returns
Type Description
UnaryCallable<CreateIdentityAwareProxyClientRequest,IdentityAwareProxyClient>

deleteIdentityAwareProxyClient(DeleteIdentityAwareProxyClientRequest request)

public final void deleteIdentityAwareProxyClient(DeleteIdentityAwareProxyClientRequest request)

Deletes an Identity Aware Proxy (IAP) OAuth client. Useful for removing obsolete clients, managing the number of clients in a given project, and cleaning up after tests. Requires that the client is owned by IAP.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   DeleteIdentityAwareProxyClientRequest request =
       DeleteIdentityAwareProxyClientRequest.newBuilder().setName("name3373707").build();
   identityAwareProxyOAuthServiceClient.deleteIdentityAwareProxyClient(request);
 }
 
Parameter
Name Description
request DeleteIdentityAwareProxyClientRequest

The request object containing all of the parameters for the API call.

deleteIdentityAwareProxyClientCallable()

public final UnaryCallable<DeleteIdentityAwareProxyClientRequest,Empty> deleteIdentityAwareProxyClientCallable()

Deletes an Identity Aware Proxy (IAP) OAuth client. Useful for removing obsolete clients, managing the number of clients in a given project, and cleaning up after tests. Requires that the client is owned by IAP.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   DeleteIdentityAwareProxyClientRequest request =
       DeleteIdentityAwareProxyClientRequest.newBuilder().setName("name3373707").build();
   ApiFuture<Empty> future =
       identityAwareProxyOAuthServiceClient
           .deleteIdentityAwareProxyClientCallable()
           .futureCall(request);
   // Do something.
   future.get();
 }
 
Returns
Type Description
UnaryCallable<DeleteIdentityAwareProxyClientRequest,Empty>

getBrand(GetBrandRequest request)

public final Brand getBrand(GetBrandRequest request)

Retrieves the OAuth brand of the project.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   GetBrandRequest request = GetBrandRequest.newBuilder().setName("name3373707").build();
   Brand response = identityAwareProxyOAuthServiceClient.getBrand(request);
 }
 
Parameter
Name Description
request GetBrandRequest

The request object containing all of the parameters for the API call.

Returns
Type Description
Brand

getBrandCallable()

public final UnaryCallable<GetBrandRequest,Brand> getBrandCallable()

Retrieves the OAuth brand of the project.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   GetBrandRequest request = GetBrandRequest.newBuilder().setName("name3373707").build();
   ApiFuture<Brand> future =
       identityAwareProxyOAuthServiceClient.getBrandCallable().futureCall(request);
   // Do something.
   Brand response = future.get();
 }
 
Returns
Type Description
UnaryCallable<GetBrandRequest,Brand>

getIdentityAwareProxyClient(GetIdentityAwareProxyClientRequest request)

public final IdentityAwareProxyClient getIdentityAwareProxyClient(GetIdentityAwareProxyClientRequest request)

Retrieves an Identity Aware Proxy (IAP) OAuth client. Requires that the client is owned by IAP.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   GetIdentityAwareProxyClientRequest request =
       GetIdentityAwareProxyClientRequest.newBuilder().setName("name3373707").build();
   IdentityAwareProxyClient response =
       identityAwareProxyOAuthServiceClient.getIdentityAwareProxyClient(request);
 }
 
Parameter
Name Description
request GetIdentityAwareProxyClientRequest

The request object containing all of the parameters for the API call.

Returns
Type Description
IdentityAwareProxyClient

getIdentityAwareProxyClientCallable()

public final UnaryCallable<GetIdentityAwareProxyClientRequest,IdentityAwareProxyClient> getIdentityAwareProxyClientCallable()

Retrieves an Identity Aware Proxy (IAP) OAuth client. Requires that the client is owned by IAP.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   GetIdentityAwareProxyClientRequest request =
       GetIdentityAwareProxyClientRequest.newBuilder().setName("name3373707").build();
   ApiFuture<IdentityAwareProxyClient> future =
       identityAwareProxyOAuthServiceClient
           .getIdentityAwareProxyClientCallable()
           .futureCall(request);
   // Do something.
   IdentityAwareProxyClient response = future.get();
 }
 
Returns
Type Description
UnaryCallable<GetIdentityAwareProxyClientRequest,IdentityAwareProxyClient>

getSettings()

public final IdentityAwareProxyOAuthServiceSettings getSettings()
Returns
Type Description
IdentityAwareProxyOAuthServiceSettings

getStub()

public IdentityAwareProxyOAuthServiceStub getStub()
Returns
Type Description
IdentityAwareProxyOAuthServiceStub

isShutdown()

public boolean isShutdown()
Returns
Type Description
boolean

isTerminated()

public boolean isTerminated()
Returns
Type Description
boolean

listBrands(ListBrandsRequest request)

public final ListBrandsResponse listBrands(ListBrandsRequest request)

Lists the existing brands for the project.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   ListBrandsRequest request =
       ListBrandsRequest.newBuilder().setParent("parent-995424086").build();
   ListBrandsResponse response = identityAwareProxyOAuthServiceClient.listBrands(request);
 }
 
Parameter
Name Description
request ListBrandsRequest

The request object containing all of the parameters for the API call.

Returns
Type Description
ListBrandsResponse

listBrandsCallable()

public final UnaryCallable<ListBrandsRequest,ListBrandsResponse> listBrandsCallable()

Lists the existing brands for the project.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   ListBrandsRequest request =
       ListBrandsRequest.newBuilder().setParent("parent-995424086").build();
   ApiFuture<ListBrandsResponse> future =
       identityAwareProxyOAuthServiceClient.listBrandsCallable().futureCall(request);
   // Do something.
   ListBrandsResponse response = future.get();
 }
 
Returns
Type Description
UnaryCallable<ListBrandsRequest,ListBrandsResponse>

listIdentityAwareProxyClients(ListIdentityAwareProxyClientsRequest request)

public final IdentityAwareProxyOAuthServiceClient.ListIdentityAwareProxyClientsPagedResponse listIdentityAwareProxyClients(ListIdentityAwareProxyClientsRequest request)

Lists the existing clients for the brand.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   ListIdentityAwareProxyClientsRequest request =
       ListIdentityAwareProxyClientsRequest.newBuilder()
           .setParent("parent-995424086")
           .setPageSize(883849137)
           .setPageToken("pageToken873572522")
           .build();
   for (IdentityAwareProxyClient element :
       identityAwareProxyOAuthServiceClient
           .listIdentityAwareProxyClients(request)
           .iterateAll()) {
     // doThingsWith(element);
   }
 }
 
Parameter
Name Description
request ListIdentityAwareProxyClientsRequest

The request object containing all of the parameters for the API call.

Returns
Type Description
IdentityAwareProxyOAuthServiceClient.ListIdentityAwareProxyClientsPagedResponse

listIdentityAwareProxyClientsCallable()

public final UnaryCallable<ListIdentityAwareProxyClientsRequest,ListIdentityAwareProxyClientsResponse> listIdentityAwareProxyClientsCallable()

Lists the existing clients for the brand.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   ListIdentityAwareProxyClientsRequest request =
       ListIdentityAwareProxyClientsRequest.newBuilder()
           .setParent("parent-995424086")
           .setPageSize(883849137)
           .setPageToken("pageToken873572522")
           .build();
   while (true) {
     ListIdentityAwareProxyClientsResponse response =
         identityAwareProxyOAuthServiceClient
             .listIdentityAwareProxyClientsCallable()
             .call(request);
     for (IdentityAwareProxyClient element : response.getIdentityAwareProxyClientsList()) {
       // doThingsWith(element);
     }
     String nextPageToken = response.getNextPageToken();
     if (!Strings.isNullOrEmpty(nextPageToken)) {
       request = request.toBuilder().setPageToken(nextPageToken).build();
     } else {
       break;
     }
   }
 }
 
Returns
Type Description
UnaryCallable<ListIdentityAwareProxyClientsRequest,ListIdentityAwareProxyClientsResponse>

listIdentityAwareProxyClientsPagedCallable()

public final UnaryCallable<ListIdentityAwareProxyClientsRequest,IdentityAwareProxyOAuthServiceClient.ListIdentityAwareProxyClientsPagedResponse> listIdentityAwareProxyClientsPagedCallable()

Lists the existing clients for the brand.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   ListIdentityAwareProxyClientsRequest request =
       ListIdentityAwareProxyClientsRequest.newBuilder()
           .setParent("parent-995424086")
           .setPageSize(883849137)
           .setPageToken("pageToken873572522")
           .build();
   ApiFuture<IdentityAwareProxyClient> future =
       identityAwareProxyOAuthServiceClient
           .listIdentityAwareProxyClientsPagedCallable()
           .futureCall(request);
   // Do something.
   for (IdentityAwareProxyClient element : future.get().iterateAll()) {
     // doThingsWith(element);
   }
 }
 
Returns
Type Description
UnaryCallable<ListIdentityAwareProxyClientsRequest,ListIdentityAwareProxyClientsPagedResponse>

resetIdentityAwareProxyClientSecret(ResetIdentityAwareProxyClientSecretRequest request)

public final IdentityAwareProxyClient resetIdentityAwareProxyClientSecret(ResetIdentityAwareProxyClientSecretRequest request)

Resets an Identity Aware Proxy (IAP) OAuth client secret. Useful if the secret was compromised. Requires that the client is owned by IAP.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   ResetIdentityAwareProxyClientSecretRequest request =
       ResetIdentityAwareProxyClientSecretRequest.newBuilder().setName("name3373707").build();
   IdentityAwareProxyClient response =
       identityAwareProxyOAuthServiceClient.resetIdentityAwareProxyClientSecret(request);
 }
 
Parameter
Name Description
request ResetIdentityAwareProxyClientSecretRequest

The request object containing all of the parameters for the API call.

Returns
Type Description
IdentityAwareProxyClient

resetIdentityAwareProxyClientSecretCallable()

public final UnaryCallable<ResetIdentityAwareProxyClientSecretRequest,IdentityAwareProxyClient> resetIdentityAwareProxyClientSecretCallable()

Resets an Identity Aware Proxy (IAP) OAuth client secret. Useful if the secret was compromised. Requires that the client is owned by IAP.

Sample code:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient =
     IdentityAwareProxyOAuthServiceClient.create()) {
   ResetIdentityAwareProxyClientSecretRequest request =
       ResetIdentityAwareProxyClientSecretRequest.newBuilder().setName("name3373707").build();
   ApiFuture<IdentityAwareProxyClient> future =
       identityAwareProxyOAuthServiceClient
           .resetIdentityAwareProxyClientSecretCallable()
           .futureCall(request);
   // Do something.
   IdentityAwareProxyClient response = future.get();
 }
 
Returns
Type Description
UnaryCallable<ResetIdentityAwareProxyClientSecretRequest,IdentityAwareProxyClient>

shutdown()

public void shutdown()

shutdownNow()

public void shutdownNow()