"use strict";
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.InterceptDeploymentGroup = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
 * A deployment group aggregates many zonal intercept backends (deployments)
 * into a single global intercept service. Consumers can connect this service
 * using an endpoint group.
 *
 * ## Example Usage
 *
 * ### Network Security Intercept Deployment Group Basic
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 *
 * const network = new gcp.compute.Network("network", {
 *     name: "example-network",
 *     autoCreateSubnetworks: false,
 * });
 * const _default = new gcp.networksecurity.InterceptDeploymentGroup("default", {
 *     interceptDeploymentGroupId: "example-dg",
 *     location: "global",
 *     network: network.id,
 *     description: "some description",
 *     labels: {
 *         foo: "bar",
 *     },
 * });
 * ```
 *
 * ## Import
 *
 * InterceptDeploymentGroup can be imported using any of these accepted formats:
 *
 * * `projects/{{project}}/locations/{{location}}/interceptDeploymentGroups/{{intercept_deployment_group_id}}`
 *
 * * `{{project}}/{{location}}/{{intercept_deployment_group_id}}`
 *
 * * `{{location}}/{{intercept_deployment_group_id}}`
 *
 * When using the `pulumi import` command, InterceptDeploymentGroup can be imported using one of the formats above. For example:
 *
 * ```sh
 * $ pulumi import gcp:networksecurity/interceptDeploymentGroup:InterceptDeploymentGroup default projects/{{project}}/locations/{{location}}/interceptDeploymentGroups/{{intercept_deployment_group_id}}
 * ```
 *
 * ```sh
 * $ pulumi import gcp:networksecurity/interceptDeploymentGroup:InterceptDeploymentGroup default {{project}}/{{location}}/{{intercept_deployment_group_id}}
 * ```
 *
 * ```sh
 * $ pulumi import gcp:networksecurity/interceptDeploymentGroup:InterceptDeploymentGroup default {{location}}/{{intercept_deployment_group_id}}
 * ```
 */
class InterceptDeploymentGroup extends pulumi.CustomResource {
    /**
     * Get an existing InterceptDeploymentGroup resource's state with the given name, ID, and optional extra
     * properties used to qualify the lookup.
     *
     * @param name The _unique_ name of the resulting resource.
     * @param id The _unique_ provider ID of the resource to lookup.
     * @param state Any extra arguments used during the lookup.
     * @param opts Optional settings to control the behavior of the CustomResource.
     */
    static get(name, id, state, opts) {
        return new InterceptDeploymentGroup(name, state, { ...opts, id: id });
    }
    /**
     * Returns true if the given object is an instance of InterceptDeploymentGroup.  This is designed to work even
     * when multiple copies of the Pulumi SDK have been loaded into the same process.
     */
    static isInstance(obj) {
        if (obj === undefined || obj === null) {
            return false;
        }
        return obj['__pulumiType'] === InterceptDeploymentGroup.__pulumiType;
    }
    constructor(name, argsOrState, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (opts.id) {
            const state = argsOrState;
            resourceInputs["connectedEndpointGroups"] = state?.connectedEndpointGroups;
            resourceInputs["createTime"] = state?.createTime;
            resourceInputs["description"] = state?.description;
            resourceInputs["effectiveLabels"] = state?.effectiveLabels;
            resourceInputs["interceptDeploymentGroupId"] = state?.interceptDeploymentGroupId;
            resourceInputs["labels"] = state?.labels;
            resourceInputs["location"] = state?.location;
            resourceInputs["locations"] = state?.locations;
            resourceInputs["name"] = state?.name;
            resourceInputs["network"] = state?.network;
            resourceInputs["project"] = state?.project;
            resourceInputs["pulumiLabels"] = state?.pulumiLabels;
            resourceInputs["reconciling"] = state?.reconciling;
            resourceInputs["state"] = state?.state;
            resourceInputs["updateTime"] = state?.updateTime;
        }
        else {
            const args = argsOrState;
            if (args?.interceptDeploymentGroupId === undefined && !opts.urn) {
                throw new Error("Missing required property 'interceptDeploymentGroupId'");
            }
            if (args?.location === undefined && !opts.urn) {
                throw new Error("Missing required property 'location'");
            }
            if (args?.network === undefined && !opts.urn) {
                throw new Error("Missing required property 'network'");
            }
            resourceInputs["description"] = args?.description;
            resourceInputs["interceptDeploymentGroupId"] = args?.interceptDeploymentGroupId;
            resourceInputs["labels"] = args?.labels;
            resourceInputs["location"] = args?.location;
            resourceInputs["network"] = args?.network;
            resourceInputs["project"] = args?.project;
            resourceInputs["connectedEndpointGroups"] = undefined /*out*/;
            resourceInputs["createTime"] = undefined /*out*/;
            resourceInputs["effectiveLabels"] = undefined /*out*/;
            resourceInputs["locations"] = undefined /*out*/;
            resourceInputs["name"] = undefined /*out*/;
            resourceInputs["pulumiLabels"] = undefined /*out*/;
            resourceInputs["reconciling"] = undefined /*out*/;
            resourceInputs["state"] = undefined /*out*/;
            resourceInputs["updateTime"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        const secretOpts = { additionalSecretOutputs: ["effectiveLabels", "pulumiLabels"] };
        opts = pulumi.mergeOptions(opts, secretOpts);
        super(InterceptDeploymentGroup.__pulumiType, name, resourceInputs, opts);
    }
}
exports.InterceptDeploymentGroup = InterceptDeploymentGroup;
/** @internal */
InterceptDeploymentGroup.__pulumiType = 'gcp:networksecurity/interceptDeploymentGroup:InterceptDeploymentGroup';
//# sourceMappingURL=interceptDeploymentGroup.js.map