/// <summary>Snippet for CreateBrandAsync</summary> public async Task CreateBrandRequestObjectAsync() { // Snippet: CreateBrandAsync(CreateBrandRequest, CallSettings) // Additional: CreateBrandAsync(CreateBrandRequest, CancellationToken) // Create client IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient = await IdentityAwareProxyOAuthServiceClient.CreateAsync(); // Initialize request argument(s) CreateBrandRequest request = new CreateBrandRequest { Parent = "", Brand = new Brand(), }; // Make the request Brand response = await identityAwareProxyOAuthServiceClient.CreateBrandAsync(request); // End snippet }
/// <summary>Snippet for ResetIdentityAwareProxyClientSecretAsync</summary> public async Task ResetIdentityAwareProxyClientSecretRequestObjectAsync() { // Snippet: ResetIdentityAwareProxyClientSecretAsync(ResetIdentityAwareProxyClientSecretRequest, CallSettings) // Additional: ResetIdentityAwareProxyClientSecretAsync(ResetIdentityAwareProxyClientSecretRequest, CancellationToken) // Create client IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient = await IdentityAwareProxyOAuthServiceClient.CreateAsync(); // Initialize request argument(s) ResetIdentityAwareProxyClientSecretRequest request = new ResetIdentityAwareProxyClientSecretRequest { Name = "", }; // Make the request IdentityAwareProxyClient response = await identityAwareProxyOAuthServiceClient.ResetIdentityAwareProxyClientSecretAsync(request); // End snippet }
/// <summary>Snippet for DeleteIdentityAwareProxyClientAsync</summary> public async Task DeleteIdentityAwareProxyClientRequestObjectAsync() { // Snippet: DeleteIdentityAwareProxyClientAsync(DeleteIdentityAwareProxyClientRequest, CallSettings) // Additional: DeleteIdentityAwareProxyClientAsync(DeleteIdentityAwareProxyClientRequest, CancellationToken) // Create client IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient = await IdentityAwareProxyOAuthServiceClient.CreateAsync(); // Initialize request argument(s) DeleteIdentityAwareProxyClientRequest request = new DeleteIdentityAwareProxyClientRequest { Name = "", }; // Make the request await identityAwareProxyOAuthServiceClient.DeleteIdentityAwareProxyClientAsync(request); // End snippet }
/// <summary>Snippet for ListIdentityAwareProxyClientsAsync</summary> public async Task ListIdentityAwareProxyClientsRequestObjectAsync() { // Snippet: ListIdentityAwareProxyClientsAsync(ListIdentityAwareProxyClientsRequest, CallSettings) // Create client IdentityAwareProxyOAuthServiceClient identityAwareProxyOAuthServiceClient = await IdentityAwareProxyOAuthServiceClient.CreateAsync(); // Initialize request argument(s) ListIdentityAwareProxyClientsRequest request = new ListIdentityAwareProxyClientsRequest { Parent = "", }; // Make the request PagedAsyncEnumerable <ListIdentityAwareProxyClientsResponse, IdentityAwareProxyClient> response = identityAwareProxyOAuthServiceClient.ListIdentityAwareProxyClientsAsync(request); // Iterate over all response items, lazily performing RPCs as required await response.ForEachAsync((IdentityAwareProxyClient item) => { // Do something with each item Console.WriteLine(item); }); // Or iterate over pages (of server-defined size), performing one RPC per page await response.AsRawResponses().ForEachAsync((ListIdentityAwareProxyClientsResponse page) => { // Do something with each page of items Console.WriteLine("A page of results:"); foreach (IdentityAwareProxyClient item in page) { // Do something with each item Console.WriteLine(item); } }); // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required int pageSize = 10; Page <IdentityAwareProxyClient> singlePage = await response.ReadPageAsync(pageSize); // Do something with the page of items Console.WriteLine($"A page of {pageSize} results (unless it's the final page):"); foreach (IdentityAwareProxyClient item in singlePage) { // Do something with each item Console.WriteLine(item); } // Store the pageToken, for when the next page is required. string nextPageToken = singlePage.NextPageToken; // End snippet }