1. Packages
  2. Google Cloud (GCP) Classic
  3. API Docs
  4. iap
  5. getClient
Google Cloud v9.4.0 published on Tuesday, Nov 4, 2025 by Pulumi

gcp.iap.getClient

Start a Neo task
Explain and create a gcp.iap.getClient resource
gcp logo
Google Cloud v9.4.0 published on Tuesday, Nov 4, 2025 by Pulumi

    Get info about a Google Cloud IAP Client.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as gcp from "@pulumi/gcp";
    
    const project = gcp.organizations.getProject({
        projectId: "foobar",
    });
    const projectClient = project.then(project => gcp.iap.getClient({
        brand: `projects/${project.number}/brands/[BRAND_NUMBER]`,
        clientId: apps.googleusercontent.com,
    }));
    
    import pulumi
    import pulumi_gcp as gcp
    
    project = gcp.organizations.get_project(project_id="foobar")
    project_client = gcp.iap.get_client(brand=f"projects/{project.number}/brands/[BRAND_NUMBER]",
        client_id=apps["googleusercontent"]["com"])
    
    package main
    
    import (
    	"fmt"
    
    	"github.com/pulumi/pulumi-gcp/sdk/v9/go/gcp/iap"
    	"github.com/pulumi/pulumi-gcp/sdk/v9/go/gcp/organizations"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		project, err := organizations.LookupProject(ctx, &organizations.LookupProjectArgs{
    			ProjectId: pulumi.StringRef("foobar"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		_, err = iap.LookupClient(ctx, &iap.LookupClientArgs{
    			Brand:    fmt.Sprintf("projects/%v/brands/[BRAND_NUMBER]", project.Number),
    			ClientId: apps.Googleusercontent.Com,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Gcp = Pulumi.Gcp;
    
    return await Deployment.RunAsync(() => 
    {
        var project = Gcp.Organizations.GetProject.Invoke(new()
        {
            ProjectId = "foobar",
        });
    
        var projectClient = Gcp.Iap.GetClient.Invoke(new()
        {
            Brand = $"projects/{project.Apply(getProjectResult => getProjectResult.Number)}/brands/[BRAND_NUMBER]",
            ClientId = apps.Googleusercontent.Com,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gcp.organizations.OrganizationsFunctions;
    import com.pulumi.gcp.organizations.inputs.GetProjectArgs;
    import com.pulumi.gcp.iap.IapFunctions;
    import com.pulumi.gcp.iap.inputs.GetClientArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var project = OrganizationsFunctions.getProject(GetProjectArgs.builder()
                .projectId("foobar")
                .build());
    
            final var projectClient = IapFunctions.getClient(GetClientArgs.builder()
                .brand(String.format("projects/%s/brands/[BRAND_NUMBER]", project.number()))
                .clientId(apps.googleusercontent().com())
                .build());
    
        }
    }
    
    variables:
      project:
        fn::invoke:
          function: gcp:organizations:getProject
          arguments:
            projectId: foobar
      projectClient:
        fn::invoke:
          function: gcp:iap:getClient
          arguments:
            brand: projects/${project.number}/brands/[BRAND_NUMBER]
            clientId: ${apps.googleusercontent.com}
    

    Using getClient

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getClient(args: GetClientArgs, opts?: InvokeOptions): Promise<GetClientResult>
    function getClientOutput(args: GetClientOutputArgs, opts?: InvokeOptions): Output<GetClientResult>
    def get_client(brand: Optional[str] = None,
                   client_id: Optional[str] = None,
                   opts: Optional[InvokeOptions] = None) -> GetClientResult
    def get_client_output(brand: Optional[pulumi.Input[str]] = None,
                   client_id: Optional[pulumi.Input[str]] = None,
                   opts: Optional[InvokeOptions] = None) -> Output[GetClientResult]
    func LookupClient(ctx *Context, args *LookupClientArgs, opts ...InvokeOption) (*LookupClientResult, error)
    func LookupClientOutput(ctx *Context, args *LookupClientOutputArgs, opts ...InvokeOption) LookupClientResultOutput

    > Note: This function is named LookupClient in the Go SDK.

    public static class GetClient 
    {
        public static Task<GetClientResult> InvokeAsync(GetClientArgs args, InvokeOptions? opts = null)
        public static Output<GetClientResult> Invoke(GetClientInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetClientResult> getClient(GetClientArgs args, InvokeOptions options)
    public static Output<GetClientResult> getClient(GetClientArgs args, InvokeOptions options)
    
    fn::invoke:
      function: gcp:iap/getClient:getClient
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Brand string
    The name of the brand.
    ClientId string
    The client_id of the brand.
    Brand string
    The name of the brand.
    ClientId string
    The client_id of the brand.
    brand String
    The name of the brand.
    clientId String
    The client_id of the brand.
    brand string
    The name of the brand.
    clientId string
    The client_id of the brand.
    brand str
    The name of the brand.
    client_id str
    The client_id of the brand.
    brand String
    The name of the brand.
    clientId String
    The client_id of the brand.

    getClient Result

    The following output properties are available:

    Brand string
    ClientId string
    DisplayName string
    Id string
    The provider-assigned unique ID for this managed resource.
    Secret string
    Brand string
    ClientId string
    DisplayName string
    Id string
    The provider-assigned unique ID for this managed resource.
    Secret string
    brand String
    clientId String
    displayName String
    id String
    The provider-assigned unique ID for this managed resource.
    secret String
    brand string
    clientId string
    displayName string
    id string
    The provider-assigned unique ID for this managed resource.
    secret string
    brand str
    client_id str
    display_name str
    id str
    The provider-assigned unique ID for this managed resource.
    secret str
    brand String
    clientId String
    displayName String
    id String
    The provider-assigned unique ID for this managed resource.
    secret String

    Package Details

    Repository
    Google Cloud (GCP) Classic pulumi/pulumi-gcp
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the google-beta Terraform Provider.
    gcp logo
    Google Cloud v9.4.0 published on Tuesday, Nov 4, 2025 by Pulumi
      Meet Neo: Your AI Platform Teammate