All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.gcp.iap.kotlin.IapFunctions.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 8.10.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.gcp.iap.kotlin

import com.pulumi.gcp.iap.IapFunctions.getAppEngineServiceIamPolicyPlain
import com.pulumi.gcp.iap.IapFunctions.getAppEngineVersionIamPolicyPlain
import com.pulumi.gcp.iap.IapFunctions.getClientPlain
import com.pulumi.gcp.iap.IapFunctions.getTunnelDestGroupIamPolicyPlain
import com.pulumi.gcp.iap.IapFunctions.getTunnelIamPolicyPlain
import com.pulumi.gcp.iap.IapFunctions.getTunnelInstanceIamPolicyPlain
import com.pulumi.gcp.iap.IapFunctions.getWebBackendServiceIamPolicyPlain
import com.pulumi.gcp.iap.IapFunctions.getWebIamPolicyPlain
import com.pulumi.gcp.iap.IapFunctions.getWebRegionBackendServiceIamPolicyPlain
import com.pulumi.gcp.iap.IapFunctions.getWebTypeAppEngineIamPolicyPlain
import com.pulumi.gcp.iap.IapFunctions.getWebTypeComputeIamPolicyPlain
import com.pulumi.gcp.iap.kotlin.inputs.GetAppEngineServiceIamPolicyPlainArgs
import com.pulumi.gcp.iap.kotlin.inputs.GetAppEngineServiceIamPolicyPlainArgsBuilder
import com.pulumi.gcp.iap.kotlin.inputs.GetAppEngineVersionIamPolicyPlainArgs
import com.pulumi.gcp.iap.kotlin.inputs.GetAppEngineVersionIamPolicyPlainArgsBuilder
import com.pulumi.gcp.iap.kotlin.inputs.GetClientPlainArgs
import com.pulumi.gcp.iap.kotlin.inputs.GetClientPlainArgsBuilder
import com.pulumi.gcp.iap.kotlin.inputs.GetTunnelDestGroupIamPolicyPlainArgs
import com.pulumi.gcp.iap.kotlin.inputs.GetTunnelDestGroupIamPolicyPlainArgsBuilder
import com.pulumi.gcp.iap.kotlin.inputs.GetTunnelIamPolicyPlainArgs
import com.pulumi.gcp.iap.kotlin.inputs.GetTunnelIamPolicyPlainArgsBuilder
import com.pulumi.gcp.iap.kotlin.inputs.GetTunnelInstanceIamPolicyPlainArgs
import com.pulumi.gcp.iap.kotlin.inputs.GetTunnelInstanceIamPolicyPlainArgsBuilder
import com.pulumi.gcp.iap.kotlin.inputs.GetWebBackendServiceIamPolicyPlainArgs
import com.pulumi.gcp.iap.kotlin.inputs.GetWebBackendServiceIamPolicyPlainArgsBuilder
import com.pulumi.gcp.iap.kotlin.inputs.GetWebIamPolicyPlainArgs
import com.pulumi.gcp.iap.kotlin.inputs.GetWebIamPolicyPlainArgsBuilder
import com.pulumi.gcp.iap.kotlin.inputs.GetWebRegionBackendServiceIamPolicyPlainArgs
import com.pulumi.gcp.iap.kotlin.inputs.GetWebRegionBackendServiceIamPolicyPlainArgsBuilder
import com.pulumi.gcp.iap.kotlin.inputs.GetWebTypeAppEngineIamPolicyPlainArgs
import com.pulumi.gcp.iap.kotlin.inputs.GetWebTypeAppEngineIamPolicyPlainArgsBuilder
import com.pulumi.gcp.iap.kotlin.inputs.GetWebTypeComputeIamPolicyPlainArgs
import com.pulumi.gcp.iap.kotlin.inputs.GetWebTypeComputeIamPolicyPlainArgsBuilder
import com.pulumi.gcp.iap.kotlin.outputs.GetAppEngineServiceIamPolicyResult
import com.pulumi.gcp.iap.kotlin.outputs.GetAppEngineVersionIamPolicyResult
import com.pulumi.gcp.iap.kotlin.outputs.GetClientResult
import com.pulumi.gcp.iap.kotlin.outputs.GetTunnelDestGroupIamPolicyResult
import com.pulumi.gcp.iap.kotlin.outputs.GetTunnelIamPolicyResult
import com.pulumi.gcp.iap.kotlin.outputs.GetTunnelInstanceIamPolicyResult
import com.pulumi.gcp.iap.kotlin.outputs.GetWebBackendServiceIamPolicyResult
import com.pulumi.gcp.iap.kotlin.outputs.GetWebIamPolicyResult
import com.pulumi.gcp.iap.kotlin.outputs.GetWebRegionBackendServiceIamPolicyResult
import com.pulumi.gcp.iap.kotlin.outputs.GetWebTypeAppEngineIamPolicyResult
import com.pulumi.gcp.iap.kotlin.outputs.GetWebTypeComputeIamPolicyResult
import kotlinx.coroutines.future.await
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import com.pulumi.gcp.iap.kotlin.outputs.GetAppEngineServiceIamPolicyResult.Companion.toKotlin as getAppEngineServiceIamPolicyResultToKotlin
import com.pulumi.gcp.iap.kotlin.outputs.GetAppEngineVersionIamPolicyResult.Companion.toKotlin as getAppEngineVersionIamPolicyResultToKotlin
import com.pulumi.gcp.iap.kotlin.outputs.GetClientResult.Companion.toKotlin as getClientResultToKotlin
import com.pulumi.gcp.iap.kotlin.outputs.GetTunnelDestGroupIamPolicyResult.Companion.toKotlin as getTunnelDestGroupIamPolicyResultToKotlin
import com.pulumi.gcp.iap.kotlin.outputs.GetTunnelIamPolicyResult.Companion.toKotlin as getTunnelIamPolicyResultToKotlin
import com.pulumi.gcp.iap.kotlin.outputs.GetTunnelInstanceIamPolicyResult.Companion.toKotlin as getTunnelInstanceIamPolicyResultToKotlin
import com.pulumi.gcp.iap.kotlin.outputs.GetWebBackendServiceIamPolicyResult.Companion.toKotlin as getWebBackendServiceIamPolicyResultToKotlin
import com.pulumi.gcp.iap.kotlin.outputs.GetWebIamPolicyResult.Companion.toKotlin as getWebIamPolicyResultToKotlin
import com.pulumi.gcp.iap.kotlin.outputs.GetWebRegionBackendServiceIamPolicyResult.Companion.toKotlin as getWebRegionBackendServiceIamPolicyResultToKotlin
import com.pulumi.gcp.iap.kotlin.outputs.GetWebTypeAppEngineIamPolicyResult.Companion.toKotlin as getWebTypeAppEngineIamPolicyResultToKotlin
import com.pulumi.gcp.iap.kotlin.outputs.GetWebTypeComputeIamPolicyResult.Companion.toKotlin as getWebTypeComputeIamPolicyResultToKotlin

public object IapFunctions {
    /**
     * Retrieves the current IAM policy data for appengineservice
     * ## example
     * 
     * ```typescript
     * import * as pulumi from "@pulumi/pulumi";
     * import * as gcp from "@pulumi/gcp";
     * const policy = gcp.iap.getAppEngineServiceIamPolicy({
     *     project: version.project,
     *     appId: version.project,
     *     service: version.service,
     * });
     * ```
     * ```python
     * import pulumi
     * import pulumi_gcp as gcp
     * policy = gcp.iap.get_app_engine_service_iam_policy(project=version["project"],
     *     app_id=version["project"],
     *     service=version["service"])
     * ```
     * ```csharp
     * using System.Collections.Generic;
     * using System.Linq;
     * using Pulumi;
     * using Gcp = Pulumi.Gcp;
     * return await Deployment.RunAsync(() =>
     * {
     *     var policy = Gcp.Iap.GetAppEngineServiceIamPolicy.Invoke(new()
     *     {
     *         Project = version.Project,
     *         AppId = version.Project,
     *         Service = version.Service,
     *     });
     * });
     * ```
     * ```go
     * package main
     * import (
     * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/iap"
     * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
     * )
     * func main() {
     * 	pulumi.Run(func(ctx *pulumi.Context) error {
     * 		_, err := iap.LookupAppEngineServiceIamPolicy(ctx, &iap.LookupAppEngineServiceIamPolicyArgs{
     * 			Project: pulumi.StringRef(version.Project),
     * 			AppId:   version.Project,
     * 			Service: version.Service,
     * 		}, nil)
     * 		if err != nil {
     * 			return err
     * 		}
     * 		return nil
     * 	})
     * }
     * ```
     * ```java
     * package generated_program;
     * import com.pulumi.Context;
     * import com.pulumi.Pulumi;
     * import com.pulumi.core.Output;
     * import com.pulumi.gcp.iap.IapFunctions;
     * import com.pulumi.gcp.iap.inputs.GetAppEngineServiceIamPolicyArgs;
     * 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 policy = IapFunctions.getAppEngineServiceIamPolicy(GetAppEngineServiceIamPolicyArgs.builder()
     *             .project(version.project())
     *             .appId(version.project())
     *             .service(version.service())
     *             .build());
     *     }
     * }
     * ```
     * ```yaml
     * variables:
     *   policy:
     *     fn::invoke:
     *       Function: gcp:iap:getAppEngineServiceIamPolicy
     *       Arguments:
     *         project: ${version.project}
     *         appId: ${version.project}
     *         service: ${version.service}
     * ```
     * 
     * @param argument A collection of arguments for invoking getAppEngineServiceIamPolicy.
     * @return A collection of values returned by getAppEngineServiceIamPolicy.
     */
    public suspend fun getAppEngineServiceIamPolicy(argument: GetAppEngineServiceIamPolicyPlainArgs): GetAppEngineServiceIamPolicyResult =
        getAppEngineServiceIamPolicyResultToKotlin(getAppEngineServiceIamPolicyPlain(argument.toJava()).await())

    /**
     * @see [getAppEngineServiceIamPolicy].
     * @param appId Id of the App Engine application. Used to find the parent resource to bind the IAM policy to
     * @param project The ID of the project in which the resource belongs.
     * If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
     * @param service Service id of the App Engine application Used to find the parent resource to bind the IAM policy to
     * @return A collection of values returned by getAppEngineServiceIamPolicy.
     */
    public suspend fun getAppEngineServiceIamPolicy(
        appId: String,
        project: String? = null,
        service: String,
    ): GetAppEngineServiceIamPolicyResult {
        val argument = GetAppEngineServiceIamPolicyPlainArgs(
            appId = appId,
            project = project,
            service = service,
        )
        return getAppEngineServiceIamPolicyResultToKotlin(getAppEngineServiceIamPolicyPlain(argument.toJava()).await())
    }

    /**
     * @see [getAppEngineServiceIamPolicy].
     * @param argument Builder for [com.pulumi.gcp.iap.kotlin.inputs.GetAppEngineServiceIamPolicyPlainArgs].
     * @return A collection of values returned by getAppEngineServiceIamPolicy.
     */
    public suspend fun getAppEngineServiceIamPolicy(argument: suspend GetAppEngineServiceIamPolicyPlainArgsBuilder.() -> Unit): GetAppEngineServiceIamPolicyResult {
        val builder = GetAppEngineServiceIamPolicyPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getAppEngineServiceIamPolicyResultToKotlin(getAppEngineServiceIamPolicyPlain(builtArgument.toJava()).await())
    }

    /**
     * Retrieves the current IAM policy data for appengineversion
     * ## example
     * 
     * ```typescript
     * import * as pulumi from "@pulumi/pulumi";
     * import * as gcp from "@pulumi/gcp";
     * const policy = gcp.iap.getAppEngineVersionIamPolicy({
     *     project: version.project,
     *     appId: version.project,
     *     service: version.service,
     *     versionId: version.versionId,
     * });
     * ```
     * ```python
     * import pulumi
     * import pulumi_gcp as gcp
     * policy = gcp.iap.get_app_engine_version_iam_policy(project=version["project"],
     *     app_id=version["project"],
     *     service=version["service"],
     *     version_id=version["versionId"])
     * ```
     * ```csharp
     * using System.Collections.Generic;
     * using System.Linq;
     * using Pulumi;
     * using Gcp = Pulumi.Gcp;
     * return await Deployment.RunAsync(() =>
     * {
     *     var policy = Gcp.Iap.GetAppEngineVersionIamPolicy.Invoke(new()
     *     {
     *         Project = version.Project,
     *         AppId = version.Project,
     *         Service = version.Service,
     *         VersionId = version.VersionId,
     *     });
     * });
     * ```
     * ```go
     * package main
     * import (
     * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/iap"
     * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
     * )
     * func main() {
     * 	pulumi.Run(func(ctx *pulumi.Context) error {
     * 		_, err := iap.LookupAppEngineVersionIamPolicy(ctx, &iap.LookupAppEngineVersionIamPolicyArgs{
     * 			Project:   pulumi.StringRef(version.Project),
     * 			AppId:     version.Project,
     * 			Service:   version.Service,
     * 			VersionId: version.VersionId,
     * 		}, nil)
     * 		if err != nil {
     * 			return err
     * 		}
     * 		return nil
     * 	})
     * }
     * ```
     * ```java
     * package generated_program;
     * import com.pulumi.Context;
     * import com.pulumi.Pulumi;
     * import com.pulumi.core.Output;
     * import com.pulumi.gcp.iap.IapFunctions;
     * import com.pulumi.gcp.iap.inputs.GetAppEngineVersionIamPolicyArgs;
     * 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 policy = IapFunctions.getAppEngineVersionIamPolicy(GetAppEngineVersionIamPolicyArgs.builder()
     *             .project(version.project())
     *             .appId(version.project())
     *             .service(version.service())
     *             .versionId(version.versionId())
     *             .build());
     *     }
     * }
     * ```
     * ```yaml
     * variables:
     *   policy:
     *     fn::invoke:
     *       Function: gcp:iap:getAppEngineVersionIamPolicy
     *       Arguments:
     *         project: ${version.project}
     *         appId: ${version.project}
     *         service: ${version.service}
     *         versionId: ${version.versionId}
     * ```
     * 
     * @param argument A collection of arguments for invoking getAppEngineVersionIamPolicy.
     * @return A collection of values returned by getAppEngineVersionIamPolicy.
     */
    public suspend fun getAppEngineVersionIamPolicy(argument: GetAppEngineVersionIamPolicyPlainArgs): GetAppEngineVersionIamPolicyResult =
        getAppEngineVersionIamPolicyResultToKotlin(getAppEngineVersionIamPolicyPlain(argument.toJava()).await())

    /**
     * @see [getAppEngineVersionIamPolicy].
     * @param appId Id of the App Engine application. Used to find the parent resource to bind the IAM policy to
     * @param project The ID of the project in which the resource belongs.
     * If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
     * @param service Service id of the App Engine application Used to find the parent resource to bind the IAM policy to
     * @param versionId Version id of the App Engine application Used to find the parent resource to bind the IAM policy to
     * @return A collection of values returned by getAppEngineVersionIamPolicy.
     */
    public suspend fun getAppEngineVersionIamPolicy(
        appId: String,
        project: String? = null,
        service: String,
        versionId: String,
    ): GetAppEngineVersionIamPolicyResult {
        val argument = GetAppEngineVersionIamPolicyPlainArgs(
            appId = appId,
            project = project,
            service = service,
            versionId = versionId,
        )
        return getAppEngineVersionIamPolicyResultToKotlin(getAppEngineVersionIamPolicyPlain(argument.toJava()).await())
    }

    /**
     * @see [getAppEngineVersionIamPolicy].
     * @param argument Builder for [com.pulumi.gcp.iap.kotlin.inputs.GetAppEngineVersionIamPolicyPlainArgs].
     * @return A collection of values returned by getAppEngineVersionIamPolicy.
     */
    public suspend fun getAppEngineVersionIamPolicy(argument: suspend GetAppEngineVersionIamPolicyPlainArgsBuilder.() -> Unit): GetAppEngineVersionIamPolicyResult {
        val builder = GetAppEngineVersionIamPolicyPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getAppEngineVersionIamPolicyResultToKotlin(getAppEngineVersionIamPolicyPlain(builtArgument.toJava()).await())
    }

    /**
     * Get info about a Google Cloud IAP Client.
     * ## Example Usage
     * ```tf
     * data "google_project" "project" {
     *   project_id = "foobar"
     * }
     * data "google_iap_client" "project_client" {
     *   brand        =  "projects/${data.google_project.project.number}/brands/[BRAND_NUMBER]"
     *   client_id    = FOO.apps.googleusercontent.com
     * }
     * ```
     * @param argument A collection of arguments for invoking getClient.
     * @return A collection of values returned by getClient.
     */
    public suspend fun getClient(argument: GetClientPlainArgs): GetClientResult =
        getClientResultToKotlin(getClientPlain(argument.toJava()).await())

    /**
     * @see [getClient].
     * @param brand The name of the brand.
     * @param clientId The client_id of the brand.
     * @return A collection of values returned by getClient.
     */
    public suspend fun getClient(brand: String, clientId: String): GetClientResult {
        val argument = GetClientPlainArgs(
            brand = brand,
            clientId = clientId,
        )
        return getClientResultToKotlin(getClientPlain(argument.toJava()).await())
    }

    /**
     * @see [getClient].
     * @param argument Builder for [com.pulumi.gcp.iap.kotlin.inputs.GetClientPlainArgs].
     * @return A collection of values returned by getClient.
     */
    public suspend fun getClient(argument: suspend GetClientPlainArgsBuilder.() -> Unit): GetClientResult {
        val builder = GetClientPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getClientResultToKotlin(getClientPlain(builtArgument.toJava()).await())
    }

    /**
     * Retrieves the current IAM policy data for tunneldestgroup
     * ## example
     * 
     * ```typescript
     * import * as pulumi from "@pulumi/pulumi";
     * import * as gcp from "@pulumi/gcp";
     * const policy = gcp.iap.getTunnelDestGroupIamPolicy({
     *     project: destGroup.project,
     *     region: destGroup.region,
     *     destGroup: destGroup.groupName,
     * });
     * ```
     * ```python
     * import pulumi
     * import pulumi_gcp as gcp
     * policy = gcp.iap.get_tunnel_dest_group_iam_policy(project=dest_group["project"],
     *     region=dest_group["region"],
     *     dest_group=dest_group["groupName"])
     * ```
     * ```csharp
     * using System.Collections.Generic;
     * using System.Linq;
     * using Pulumi;
     * using Gcp = Pulumi.Gcp;
     * return await Deployment.RunAsync(() =>
     * {
     *     var policy = Gcp.Iap.GetTunnelDestGroupIamPolicy.Invoke(new()
     *     {
     *         Project = destGroup.Project,
     *         Region = destGroup.Region,
     *         DestGroup = destGroup.GroupName,
     *     });
     * });
     * ```
     * ```go
     * package main
     * import (
     * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/iap"
     * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
     * )
     * func main() {
     * 	pulumi.Run(func(ctx *pulumi.Context) error {
     * 		_, err := iap.LookupTunnelDestGroupIamPolicy(ctx, &iap.LookupTunnelDestGroupIamPolicyArgs{
     * 			Project:   pulumi.StringRef(destGroup.Project),
     * 			Region:    pulumi.StringRef(destGroup.Region),
     * 			DestGroup: destGroup.GroupName,
     * 		}, nil)
     * 		if err != nil {
     * 			return err
     * 		}
     * 		return nil
     * 	})
     * }
     * ```
     * ```java
     * package generated_program;
     * import com.pulumi.Context;
     * import com.pulumi.Pulumi;
     * import com.pulumi.core.Output;
     * import com.pulumi.gcp.iap.IapFunctions;
     * import com.pulumi.gcp.iap.inputs.GetTunnelDestGroupIamPolicyArgs;
     * 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 policy = IapFunctions.getTunnelDestGroupIamPolicy(GetTunnelDestGroupIamPolicyArgs.builder()
     *             .project(destGroup.project())
     *             .region(destGroup.region())
     *             .destGroup(destGroup.groupName())
     *             .build());
     *     }
     * }
     * ```
     * ```yaml
     * variables:
     *   policy:
     *     fn::invoke:
     *       Function: gcp:iap:getTunnelDestGroupIamPolicy
     *       Arguments:
     *         project: ${destGroup.project}
     *         region: ${destGroup.region}
     *         destGroup: ${destGroup.groupName}
     * ```
     * 
     * @param argument A collection of arguments for invoking getTunnelDestGroupIamPolicy.
     * @return A collection of values returned by getTunnelDestGroupIamPolicy.
     */
    public suspend fun getTunnelDestGroupIamPolicy(argument: GetTunnelDestGroupIamPolicyPlainArgs): GetTunnelDestGroupIamPolicyResult =
        getTunnelDestGroupIamPolicyResultToKotlin(getTunnelDestGroupIamPolicyPlain(argument.toJava()).await())

    /**
     * @see [getTunnelDestGroupIamPolicy].
     * @param destGroup
     * @param project The ID of the project in which the resource belongs.
     * If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
     * @param region The region of the tunnel group. Must be the same as the network resources in the group.
     * Used to find the parent resource to bind the IAM policy to. If not specified,
     * the value will be parsed from the identifier of the parent resource. If no region is provided in the parent identifier and no
     * region is specified, it is taken from the provider configuration.
     * @return A collection of values returned by getTunnelDestGroupIamPolicy.
     */
    public suspend fun getTunnelDestGroupIamPolicy(
        destGroup: String,
        project: String? = null,
        region: String? = null,
    ): GetTunnelDestGroupIamPolicyResult {
        val argument = GetTunnelDestGroupIamPolicyPlainArgs(
            destGroup = destGroup,
            project = project,
            region = region,
        )
        return getTunnelDestGroupIamPolicyResultToKotlin(getTunnelDestGroupIamPolicyPlain(argument.toJava()).await())
    }

    /**
     * @see [getTunnelDestGroupIamPolicy].
     * @param argument Builder for [com.pulumi.gcp.iap.kotlin.inputs.GetTunnelDestGroupIamPolicyPlainArgs].
     * @return A collection of values returned by getTunnelDestGroupIamPolicy.
     */
    public suspend fun getTunnelDestGroupIamPolicy(argument: suspend GetTunnelDestGroupIamPolicyPlainArgsBuilder.() -> Unit): GetTunnelDestGroupIamPolicyResult {
        val builder = GetTunnelDestGroupIamPolicyPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getTunnelDestGroupIamPolicyResultToKotlin(getTunnelDestGroupIamPolicyPlain(builtArgument.toJava()).await())
    }

    /**
     * Retrieves the current IAM policy data for tunnel
     * ## example
     * 
     * ```typescript
     * import * as pulumi from "@pulumi/pulumi";
     * import * as gcp from "@pulumi/gcp";
     * const policy = gcp.iap.getTunnelIamPolicy({
     *     project: projectService.project,
     * });
     * ```
     * ```python
     * import pulumi
     * import pulumi_gcp as gcp
     * policy = gcp.iap.get_tunnel_iam_policy(project=project_service["project"])
     * ```
     * ```csharp
     * using System.Collections.Generic;
     * using System.Linq;
     * using Pulumi;
     * using Gcp = Pulumi.Gcp;
     * return await Deployment.RunAsync(() =>
     * {
     *     var policy = Gcp.Iap.GetTunnelIamPolicy.Invoke(new()
     *     {
     *         Project = projectService.Project,
     *     });
     * });
     * ```
     * ```go
     * package main
     * import (
     * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/iap"
     * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
     * )
     * func main() {
     * 	pulumi.Run(func(ctx *pulumi.Context) error {
     * 		_, err := iap.LookupTunnelIamPolicy(ctx, &iap.LookupTunnelIamPolicyArgs{
     * 			Project: pulumi.StringRef(projectService.Project),
     * 		}, nil)
     * 		if err != nil {
     * 			return err
     * 		}
     * 		return nil
     * 	})
     * }
     * ```
     * ```java
     * package generated_program;
     * import com.pulumi.Context;
     * import com.pulumi.Pulumi;
     * import com.pulumi.core.Output;
     * import com.pulumi.gcp.iap.IapFunctions;
     * import com.pulumi.gcp.iap.inputs.GetTunnelIamPolicyArgs;
     * 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 policy = IapFunctions.getTunnelIamPolicy(GetTunnelIamPolicyArgs.builder()
     *             .project(projectService.project())
     *             .build());
     *     }
     * }
     * ```
     * ```yaml
     * variables:
     *   policy:
     *     fn::invoke:
     *       Function: gcp:iap:getTunnelIamPolicy
     *       Arguments:
     *         project: ${projectService.project}
     * ```
     * 
     * @param argument A collection of arguments for invoking getTunnelIamPolicy.
     * @return A collection of values returned by getTunnelIamPolicy.
     */
    public suspend fun getTunnelIamPolicy(argument: GetTunnelIamPolicyPlainArgs): GetTunnelIamPolicyResult =
        getTunnelIamPolicyResultToKotlin(getTunnelIamPolicyPlain(argument.toJava()).await())

    /**
     * @see [getTunnelIamPolicy].
     * @param project The ID of the project in which the resource belongs.
     * If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
     * @return A collection of values returned by getTunnelIamPolicy.
     */
    public suspend fun getTunnelIamPolicy(project: String? = null): GetTunnelIamPolicyResult {
        val argument = GetTunnelIamPolicyPlainArgs(
            project = project,
        )
        return getTunnelIamPolicyResultToKotlin(getTunnelIamPolicyPlain(argument.toJava()).await())
    }

    /**
     * @see [getTunnelIamPolicy].
     * @param argument Builder for [com.pulumi.gcp.iap.kotlin.inputs.GetTunnelIamPolicyPlainArgs].
     * @return A collection of values returned by getTunnelIamPolicy.
     */
    public suspend fun getTunnelIamPolicy(argument: suspend GetTunnelIamPolicyPlainArgsBuilder.() -> Unit): GetTunnelIamPolicyResult {
        val builder = GetTunnelIamPolicyPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getTunnelIamPolicyResultToKotlin(getTunnelIamPolicyPlain(builtArgument.toJava()).await())
    }

    /**
     * Retrieves the current IAM policy data for tunnelinstance
     * ## example
     * 
     * ```typescript
     * import * as pulumi from "@pulumi/pulumi";
     * import * as gcp from "@pulumi/gcp";
     * const policy = gcp.iap.getTunnelInstanceIamPolicy({
     *     project: tunnelvm.project,
     *     zone: tunnelvm.zone,
     *     instance: tunnelvm.name,
     * });
     * ```
     * ```python
     * import pulumi
     * import pulumi_gcp as gcp
     * policy = gcp.iap.get_tunnel_instance_iam_policy(project=tunnelvm["project"],
     *     zone=tunnelvm["zone"],
     *     instance=tunnelvm["name"])
     * ```
     * ```csharp
     * using System.Collections.Generic;
     * using System.Linq;
     * using Pulumi;
     * using Gcp = Pulumi.Gcp;
     * return await Deployment.RunAsync(() =>
     * {
     *     var policy = Gcp.Iap.GetTunnelInstanceIamPolicy.Invoke(new()
     *     {
     *         Project = tunnelvm.Project,
     *         Zone = tunnelvm.Zone,
     *         Instance = tunnelvm.Name,
     *     });
     * });
     * ```
     * ```go
     * package main
     * import (
     * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/iap"
     * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
     * )
     * func main() {
     * 	pulumi.Run(func(ctx *pulumi.Context) error {
     * 		_, err := iap.GetTunnelInstanceIamPolicy(ctx, &iap.GetTunnelInstanceIamPolicyArgs{
     * 			Project:  pulumi.StringRef(tunnelvm.Project),
     * 			Zone:     pulumi.StringRef(tunnelvm.Zone),
     * 			Instance: tunnelvm.Name,
     * 		}, nil)
     * 		if err != nil {
     * 			return err
     * 		}
     * 		return nil
     * 	})
     * }
     * ```
     * ```java
     * package generated_program;
     * import com.pulumi.Context;
     * import com.pulumi.Pulumi;
     * import com.pulumi.core.Output;
     * import com.pulumi.gcp.iap.IapFunctions;
     * import com.pulumi.gcp.iap.inputs.GetTunnelInstanceIamPolicyArgs;
     * 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 policy = IapFunctions.getTunnelInstanceIamPolicy(GetTunnelInstanceIamPolicyArgs.builder()
     *             .project(tunnelvm.project())
     *             .zone(tunnelvm.zone())
     *             .instance(tunnelvm.name())
     *             .build());
     *     }
     * }
     * ```
     * ```yaml
     * variables:
     *   policy:
     *     fn::invoke:
     *       Function: gcp:iap:getTunnelInstanceIamPolicy
     *       Arguments:
     *         project: ${tunnelvm.project}
     *         zone: ${tunnelvm.zone}
     *         instance: ${tunnelvm.name}
     * ```
     * 
     * @param argument A collection of arguments for invoking getTunnelInstanceIamPolicy.
     * @return A collection of values returned by getTunnelInstanceIamPolicy.
     */
    public suspend fun getTunnelInstanceIamPolicy(argument: GetTunnelInstanceIamPolicyPlainArgs): GetTunnelInstanceIamPolicyResult =
        getTunnelInstanceIamPolicyResultToKotlin(getTunnelInstanceIamPolicyPlain(argument.toJava()).await())

    /**
     * @see [getTunnelInstanceIamPolicy].
     * @param instance Used to find the parent resource to bind the IAM policy to
     * @param project The ID of the project in which the resource belongs.
     * If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
     * @param zone
     * @return A collection of values returned by getTunnelInstanceIamPolicy.
     */
    public suspend fun getTunnelInstanceIamPolicy(
        instance: String,
        project: String? = null,
        zone: String? = null,
    ): GetTunnelInstanceIamPolicyResult {
        val argument = GetTunnelInstanceIamPolicyPlainArgs(
            instance = instance,
            project = project,
            zone = zone,
        )
        return getTunnelInstanceIamPolicyResultToKotlin(getTunnelInstanceIamPolicyPlain(argument.toJava()).await())
    }

    /**
     * @see [getTunnelInstanceIamPolicy].
     * @param argument Builder for [com.pulumi.gcp.iap.kotlin.inputs.GetTunnelInstanceIamPolicyPlainArgs].
     * @return A collection of values returned by getTunnelInstanceIamPolicy.
     */
    public suspend fun getTunnelInstanceIamPolicy(argument: suspend GetTunnelInstanceIamPolicyPlainArgsBuilder.() -> Unit): GetTunnelInstanceIamPolicyResult {
        val builder = GetTunnelInstanceIamPolicyPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getTunnelInstanceIamPolicyResultToKotlin(getTunnelInstanceIamPolicyPlain(builtArgument.toJava()).await())
    }

    /**
     * Retrieves the current IAM policy data for webbackendservice
     * ## example
     * 
     * ```typescript
     * import * as pulumi from "@pulumi/pulumi";
     * import * as gcp from "@pulumi/gcp";
     * const policy = gcp.iap.getWebBackendServiceIamPolicy({
     *     project: _default.project,
     *     webBackendService: _default.name,
     * });
     * ```
     * ```python
     * import pulumi
     * import pulumi_gcp as gcp
     * policy = gcp.iap.get_web_backend_service_iam_policy(project=default["project"],
     *     web_backend_service=default["name"])
     * ```
     * ```csharp
     * using System.Collections.Generic;
     * using System.Linq;
     * using Pulumi;
     * using Gcp = Pulumi.Gcp;
     * return await Deployment.RunAsync(() =>
     * {
     *     var policy = Gcp.Iap.GetWebBackendServiceIamPolicy.Invoke(new()
     *     {
     *         Project = @default.Project,
     *         WebBackendService = @default.Name,
     *     });
     * });
     * ```
     * ```go
     * package main
     * import (
     * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/iap"
     * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
     * )
     * func main() {
     * 	pulumi.Run(func(ctx *pulumi.Context) error {
     * 		_, err := iap.LookupWebBackendServiceIamPolicy(ctx, &iap.LookupWebBackendServiceIamPolicyArgs{
     * 			Project:           pulumi.StringRef(_default.Project),
     * 			WebBackendService: _default.Name,
     * 		}, nil)
     * 		if err != nil {
     * 			return err
     * 		}
     * 		return nil
     * 	})
     * }
     * ```
     * ```java
     * package generated_program;
     * import com.pulumi.Context;
     * import com.pulumi.Pulumi;
     * import com.pulumi.core.Output;
     * import com.pulumi.gcp.iap.IapFunctions;
     * import com.pulumi.gcp.iap.inputs.GetWebBackendServiceIamPolicyArgs;
     * 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 policy = IapFunctions.getWebBackendServiceIamPolicy(GetWebBackendServiceIamPolicyArgs.builder()
     *             .project(default_.project())
     *             .webBackendService(default_.name())
     *             .build());
     *     }
     * }
     * ```
     * ```yaml
     * variables:
     *   policy:
     *     fn::invoke:
     *       Function: gcp:iap:getWebBackendServiceIamPolicy
     *       Arguments:
     *         project: ${default.project}
     *         webBackendService: ${default.name}
     * ```
     * 
     * @param argument A collection of arguments for invoking getWebBackendServiceIamPolicy.
     * @return A collection of values returned by getWebBackendServiceIamPolicy.
     */
    public suspend fun getWebBackendServiceIamPolicy(argument: GetWebBackendServiceIamPolicyPlainArgs): GetWebBackendServiceIamPolicyResult =
        getWebBackendServiceIamPolicyResultToKotlin(getWebBackendServiceIamPolicyPlain(argument.toJava()).await())

    /**
     * @see [getWebBackendServiceIamPolicy].
     * @param project The ID of the project in which the resource belongs.
     * If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
     * @param webBackendService Used to find the parent resource to bind the IAM policy to
     * @return A collection of values returned by getWebBackendServiceIamPolicy.
     */
    public suspend fun getWebBackendServiceIamPolicy(
        project: String? = null,
        webBackendService: String,
    ): GetWebBackendServiceIamPolicyResult {
        val argument = GetWebBackendServiceIamPolicyPlainArgs(
            project = project,
            webBackendService = webBackendService,
        )
        return getWebBackendServiceIamPolicyResultToKotlin(getWebBackendServiceIamPolicyPlain(argument.toJava()).await())
    }

    /**
     * @see [getWebBackendServiceIamPolicy].
     * @param argument Builder for [com.pulumi.gcp.iap.kotlin.inputs.GetWebBackendServiceIamPolicyPlainArgs].
     * @return A collection of values returned by getWebBackendServiceIamPolicy.
     */
    public suspend fun getWebBackendServiceIamPolicy(argument: suspend GetWebBackendServiceIamPolicyPlainArgsBuilder.() -> Unit): GetWebBackendServiceIamPolicyResult {
        val builder = GetWebBackendServiceIamPolicyPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getWebBackendServiceIamPolicyResultToKotlin(getWebBackendServiceIamPolicyPlain(builtArgument.toJava()).await())
    }

    /**
     * Retrieves the current IAM policy data for web
     * ## example
     * 
     * ```typescript
     * import * as pulumi from "@pulumi/pulumi";
     * import * as gcp from "@pulumi/gcp";
     * const policy = gcp.iap.getWebIamPolicy({
     *     project: projectService.project,
     * });
     * ```
     * ```python
     * import pulumi
     * import pulumi_gcp as gcp
     * policy = gcp.iap.get_web_iam_policy(project=project_service["project"])
     * ```
     * ```csharp
     * using System.Collections.Generic;
     * using System.Linq;
     * using Pulumi;
     * using Gcp = Pulumi.Gcp;
     * return await Deployment.RunAsync(() =>
     * {
     *     var policy = Gcp.Iap.GetWebIamPolicy.Invoke(new()
     *     {
     *         Project = projectService.Project,
     *     });
     * });
     * ```
     * ```go
     * package main
     * import (
     * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/iap"
     * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
     * )
     * func main() {
     * 	pulumi.Run(func(ctx *pulumi.Context) error {
     * 		_, err := iap.LookupWebIamPolicy(ctx, &iap.LookupWebIamPolicyArgs{
     * 			Project: pulumi.StringRef(projectService.Project),
     * 		}, nil)
     * 		if err != nil {
     * 			return err
     * 		}
     * 		return nil
     * 	})
     * }
     * ```
     * ```java
     * package generated_program;
     * import com.pulumi.Context;
     * import com.pulumi.Pulumi;
     * import com.pulumi.core.Output;
     * import com.pulumi.gcp.iap.IapFunctions;
     * import com.pulumi.gcp.iap.inputs.GetWebIamPolicyArgs;
     * 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 policy = IapFunctions.getWebIamPolicy(GetWebIamPolicyArgs.builder()
     *             .project(projectService.project())
     *             .build());
     *     }
     * }
     * ```
     * ```yaml
     * variables:
     *   policy:
     *     fn::invoke:
     *       Function: gcp:iap:getWebIamPolicy
     *       Arguments:
     *         project: ${projectService.project}
     * ```
     * 
     * @param argument A collection of arguments for invoking getWebIamPolicy.
     * @return A collection of values returned by getWebIamPolicy.
     */
    public suspend fun getWebIamPolicy(argument: GetWebIamPolicyPlainArgs): GetWebIamPolicyResult =
        getWebIamPolicyResultToKotlin(getWebIamPolicyPlain(argument.toJava()).await())

    /**
     * @see [getWebIamPolicy].
     * @param project The ID of the project in which the resource belongs.
     * If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
     * @return A collection of values returned by getWebIamPolicy.
     */
    public suspend fun getWebIamPolicy(project: String? = null): GetWebIamPolicyResult {
        val argument = GetWebIamPolicyPlainArgs(
            project = project,
        )
        return getWebIamPolicyResultToKotlin(getWebIamPolicyPlain(argument.toJava()).await())
    }

    /**
     * @see [getWebIamPolicy].
     * @param argument Builder for [com.pulumi.gcp.iap.kotlin.inputs.GetWebIamPolicyPlainArgs].
     * @return A collection of values returned by getWebIamPolicy.
     */
    public suspend fun getWebIamPolicy(argument: suspend GetWebIamPolicyPlainArgsBuilder.() -> Unit): GetWebIamPolicyResult {
        val builder = GetWebIamPolicyPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getWebIamPolicyResultToKotlin(getWebIamPolicyPlain(builtArgument.toJava()).await())
    }

    /**
     * Retrieves the current IAM policy data for webregionbackendservice
     * ## example
     * 
     * ```typescript
     * import * as pulumi from "@pulumi/pulumi";
     * import * as gcp from "@pulumi/gcp";
     * const policy = gcp.iap.getWebRegionBackendServiceIamPolicy({
     *     project: _default.project,
     *     region: _default.region,
     *     webRegionBackendService: _default.name,
     * });
     * ```
     * ```python
     * import pulumi
     * import pulumi_gcp as gcp
     * policy = gcp.iap.get_web_region_backend_service_iam_policy(project=default["project"],
     *     region=default["region"],
     *     web_region_backend_service=default["name"])
     * ```
     * ```csharp
     * using System.Collections.Generic;
     * using System.Linq;
     * using Pulumi;
     * using Gcp = Pulumi.Gcp;
     * return await Deployment.RunAsync(() =>
     * {
     *     var policy = Gcp.Iap.GetWebRegionBackendServiceIamPolicy.Invoke(new()
     *     {
     *         Project = @default.Project,
     *         Region = @default.Region,
     *         WebRegionBackendService = @default.Name,
     *     });
     * });
     * ```
     * ```go
     * package main
     * import (
     * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/iap"
     * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
     * )
     * func main() {
     * 	pulumi.Run(func(ctx *pulumi.Context) error {
     * 		_, err := iap.LookupWebRegionBackendServiceIamPolicy(ctx, &iap.LookupWebRegionBackendServiceIamPolicyArgs{
     * 			Project:                 pulumi.StringRef(_default.Project),
     * 			Region:                  pulumi.StringRef(_default.Region),
     * 			WebRegionBackendService: _default.Name,
     * 		}, nil)
     * 		if err != nil {
     * 			return err
     * 		}
     * 		return nil
     * 	})
     * }
     * ```
     * ```java
     * package generated_program;
     * import com.pulumi.Context;
     * import com.pulumi.Pulumi;
     * import com.pulumi.core.Output;
     * import com.pulumi.gcp.iap.IapFunctions;
     * import com.pulumi.gcp.iap.inputs.GetWebRegionBackendServiceIamPolicyArgs;
     * 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 policy = IapFunctions.getWebRegionBackendServiceIamPolicy(GetWebRegionBackendServiceIamPolicyArgs.builder()
     *             .project(default_.project())
     *             .region(default_.region())
     *             .webRegionBackendService(default_.name())
     *             .build());
     *     }
     * }
     * ```
     * ```yaml
     * variables:
     *   policy:
     *     fn::invoke:
     *       Function: gcp:iap:getWebRegionBackendServiceIamPolicy
     *       Arguments:
     *         project: ${default.project}
     *         region: ${default.region}
     *         webRegionBackendService: ${default.name}
     * ```
     * 
     * @param argument A collection of arguments for invoking getWebRegionBackendServiceIamPolicy.
     * @return A collection of values returned by getWebRegionBackendServiceIamPolicy.
     */
    public suspend fun getWebRegionBackendServiceIamPolicy(argument: GetWebRegionBackendServiceIamPolicyPlainArgs): GetWebRegionBackendServiceIamPolicyResult =
        getWebRegionBackendServiceIamPolicyResultToKotlin(getWebRegionBackendServiceIamPolicyPlain(argument.toJava()).await())

    /**
     * @see [getWebRegionBackendServiceIamPolicy].
     * @param project The ID of the project in which the resource belongs.
     * If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
     * @param region
     * @param webRegionBackendService Used to find the parent resource to bind the IAM policy to
     * @return A collection of values returned by getWebRegionBackendServiceIamPolicy.
     */
    public suspend fun getWebRegionBackendServiceIamPolicy(
        project: String? = null,
        region: String? = null,
        webRegionBackendService: String,
    ): GetWebRegionBackendServiceIamPolicyResult {
        val argument = GetWebRegionBackendServiceIamPolicyPlainArgs(
            project = project,
            region = region,
            webRegionBackendService = webRegionBackendService,
        )
        return getWebRegionBackendServiceIamPolicyResultToKotlin(getWebRegionBackendServiceIamPolicyPlain(argument.toJava()).await())
    }

    /**
     * @see [getWebRegionBackendServiceIamPolicy].
     * @param argument Builder for [com.pulumi.gcp.iap.kotlin.inputs.GetWebRegionBackendServiceIamPolicyPlainArgs].
     * @return A collection of values returned by getWebRegionBackendServiceIamPolicy.
     */
    public suspend fun getWebRegionBackendServiceIamPolicy(argument: suspend GetWebRegionBackendServiceIamPolicyPlainArgsBuilder.() -> Unit): GetWebRegionBackendServiceIamPolicyResult {
        val builder = GetWebRegionBackendServiceIamPolicyPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getWebRegionBackendServiceIamPolicyResultToKotlin(getWebRegionBackendServiceIamPolicyPlain(builtArgument.toJava()).await())
    }

    /**
     * Retrieves the current IAM policy data for webtypeappengine
     * ## example
     * 
     * ```typescript
     * import * as pulumi from "@pulumi/pulumi";
     * import * as gcp from "@pulumi/gcp";
     * const policy = gcp.iap.getWebTypeAppEngineIamPolicy({
     *     project: app.project,
     *     appId: app.appId,
     * });
     * ```
     * ```python
     * import pulumi
     * import pulumi_gcp as gcp
     * policy = gcp.iap.get_web_type_app_engine_iam_policy(project=app["project"],
     *     app_id=app["appId"])
     * ```
     * ```csharp
     * using System.Collections.Generic;
     * using System.Linq;
     * using Pulumi;
     * using Gcp = Pulumi.Gcp;
     * return await Deployment.RunAsync(() =>
     * {
     *     var policy = Gcp.Iap.GetWebTypeAppEngineIamPolicy.Invoke(new()
     *     {
     *         Project = app.Project,
     *         AppId = app.AppId,
     *     });
     * });
     * ```
     * ```go
     * package main
     * import (
     * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/iap"
     * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
     * )
     * func main() {
     * 	pulumi.Run(func(ctx *pulumi.Context) error {
     * 		_, err := iap.GetWebTypeAppEngineIamPolicy(ctx, &iap.GetWebTypeAppEngineIamPolicyArgs{
     * 			Project: pulumi.StringRef(app.Project),
     * 			AppId:   app.AppId,
     * 		}, nil)
     * 		if err != nil {
     * 			return err
     * 		}
     * 		return nil
     * 	})
     * }
     * ```
     * ```java
     * package generated_program;
     * import com.pulumi.Context;
     * import com.pulumi.Pulumi;
     * import com.pulumi.core.Output;
     * import com.pulumi.gcp.iap.IapFunctions;
     * import com.pulumi.gcp.iap.inputs.GetWebTypeAppEngineIamPolicyArgs;
     * 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 policy = IapFunctions.getWebTypeAppEngineIamPolicy(GetWebTypeAppEngineIamPolicyArgs.builder()
     *             .project(app.project())
     *             .appId(app.appId())
     *             .build());
     *     }
     * }
     * ```
     * ```yaml
     * variables:
     *   policy:
     *     fn::invoke:
     *       Function: gcp:iap:getWebTypeAppEngineIamPolicy
     *       Arguments:
     *         project: ${app.project}
     *         appId: ${app.appId}
     * ```
     * 
     * @param argument A collection of arguments for invoking getWebTypeAppEngineIamPolicy.
     * @return A collection of values returned by getWebTypeAppEngineIamPolicy.
     */
    public suspend fun getWebTypeAppEngineIamPolicy(argument: GetWebTypeAppEngineIamPolicyPlainArgs): GetWebTypeAppEngineIamPolicyResult =
        getWebTypeAppEngineIamPolicyResultToKotlin(getWebTypeAppEngineIamPolicyPlain(argument.toJava()).await())

    /**
     * @see [getWebTypeAppEngineIamPolicy].
     * @param appId Id of the App Engine application. Used to find the parent resource to bind the IAM policy to
     * @param project The ID of the project in which the resource belongs.
     * If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
     * @return A collection of values returned by getWebTypeAppEngineIamPolicy.
     */
    public suspend fun getWebTypeAppEngineIamPolicy(appId: String, project: String? = null): GetWebTypeAppEngineIamPolicyResult {
        val argument = GetWebTypeAppEngineIamPolicyPlainArgs(
            appId = appId,
            project = project,
        )
        return getWebTypeAppEngineIamPolicyResultToKotlin(getWebTypeAppEngineIamPolicyPlain(argument.toJava()).await())
    }

    /**
     * @see [getWebTypeAppEngineIamPolicy].
     * @param argument Builder for [com.pulumi.gcp.iap.kotlin.inputs.GetWebTypeAppEngineIamPolicyPlainArgs].
     * @return A collection of values returned by getWebTypeAppEngineIamPolicy.
     */
    public suspend fun getWebTypeAppEngineIamPolicy(argument: suspend GetWebTypeAppEngineIamPolicyPlainArgsBuilder.() -> Unit): GetWebTypeAppEngineIamPolicyResult {
        val builder = GetWebTypeAppEngineIamPolicyPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getWebTypeAppEngineIamPolicyResultToKotlin(getWebTypeAppEngineIamPolicyPlain(builtArgument.toJava()).await())
    }

    /**
     * Retrieves the current IAM policy data for webtypecompute
     * ## example
     * 
     * ```typescript
     * import * as pulumi from "@pulumi/pulumi";
     * import * as gcp from "@pulumi/gcp";
     * const policy = gcp.iap.getWebTypeComputeIamPolicy({
     *     project: projectService.project,
     * });
     * ```
     * ```python
     * import pulumi
     * import pulumi_gcp as gcp
     * policy = gcp.iap.get_web_type_compute_iam_policy(project=project_service["project"])
     * ```
     * ```csharp
     * using System.Collections.Generic;
     * using System.Linq;
     * using Pulumi;
     * using Gcp = Pulumi.Gcp;
     * return await Deployment.RunAsync(() =>
     * {
     *     var policy = Gcp.Iap.GetWebTypeComputeIamPolicy.Invoke(new()
     *     {
     *         Project = projectService.Project,
     *     });
     * });
     * ```
     * ```go
     * package main
     * import (
     * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/iap"
     * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
     * )
     * func main() {
     * 	pulumi.Run(func(ctx *pulumi.Context) error {
     * 		_, err := iap.LookupWebTypeComputeIamPolicy(ctx, &iap.LookupWebTypeComputeIamPolicyArgs{
     * 			Project: pulumi.StringRef(projectService.Project),
     * 		}, nil)
     * 		if err != nil {
     * 			return err
     * 		}
     * 		return nil
     * 	})
     * }
     * ```
     * ```java
     * package generated_program;
     * import com.pulumi.Context;
     * import com.pulumi.Pulumi;
     * import com.pulumi.core.Output;
     * import com.pulumi.gcp.iap.IapFunctions;
     * import com.pulumi.gcp.iap.inputs.GetWebTypeComputeIamPolicyArgs;
     * 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 policy = IapFunctions.getWebTypeComputeIamPolicy(GetWebTypeComputeIamPolicyArgs.builder()
     *             .project(projectService.project())
     *             .build());
     *     }
     * }
     * ```
     * ```yaml
     * variables:
     *   policy:
     *     fn::invoke:
     *       Function: gcp:iap:getWebTypeComputeIamPolicy
     *       Arguments:
     *         project: ${projectService.project}
     * ```
     * 
     * @param argument A collection of arguments for invoking getWebTypeComputeIamPolicy.
     * @return A collection of values returned by getWebTypeComputeIamPolicy.
     */
    public suspend fun getWebTypeComputeIamPolicy(argument: GetWebTypeComputeIamPolicyPlainArgs): GetWebTypeComputeIamPolicyResult =
        getWebTypeComputeIamPolicyResultToKotlin(getWebTypeComputeIamPolicyPlain(argument.toJava()).await())

    /**
     * @see [getWebTypeComputeIamPolicy].
     * @param project The ID of the project in which the resource belongs.
     * If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
     * @return A collection of values returned by getWebTypeComputeIamPolicy.
     */
    public suspend fun getWebTypeComputeIamPolicy(project: String? = null): GetWebTypeComputeIamPolicyResult {
        val argument = GetWebTypeComputeIamPolicyPlainArgs(
            project = project,
        )
        return getWebTypeComputeIamPolicyResultToKotlin(getWebTypeComputeIamPolicyPlain(argument.toJava()).await())
    }

    /**
     * @see [getWebTypeComputeIamPolicy].
     * @param argument Builder for [com.pulumi.gcp.iap.kotlin.inputs.GetWebTypeComputeIamPolicyPlainArgs].
     * @return A collection of values returned by getWebTypeComputeIamPolicy.
     */
    public suspend fun getWebTypeComputeIamPolicy(argument: suspend GetWebTypeComputeIamPolicyPlainArgsBuilder.() -> Unit): GetWebTypeComputeIamPolicyResult {
        val builder = GetWebTypeComputeIamPolicyPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getWebTypeComputeIamPolicyResultToKotlin(getWebTypeComputeIamPolicyPlain(builtArgument.toJava()).await())
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy