"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.SecurityScanConfig = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
 * A ScanConfig resource contains the configurations to launch a scan.
 *
 * To get more information about ScanConfig, see:
 *
 * * [API documentation](https://cloud.google.com/security-scanner/docs/reference/rest/v1beta/projects.scanConfigs)
 * * How-to Guides
 *     * [Using Cloud Security Scanner](https://cloud.google.com/security-scanner/docs/scanning)
 *
 * ## Example Usage
 *
 * ### Scan Config Basic
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 *
 * const scannerStaticIp = new gcp.compute.Address("scanner_static_ip", {name: "scan-basic-static-ip"});
 * const scan_config = new gcp.compute.SecurityScanConfig("scan-config", {
 *     displayName: "scan-config",
 *     startingUrls: [pulumi.interpolate`http://${scannerStaticIp.address}`],
 *     targetPlatforms: ["COMPUTE"],
 * });
 * ```
 *
 * ## Import
 *
 * ScanConfig can be imported using any of these accepted formats:
 *
 * * `{{project}}/{{name}}`
 *
 * * `{{project}} {{name}}`
 *
 * * `{{name}}`
 *
 * When using the `pulumi import` command, ScanConfig can be imported using one of the formats above. For example:
 *
 * ```sh
 * $ pulumi import gcp:compute/securityScanConfig:SecurityScanConfig default {{project}}/{{name}}
 * ```
 *
 * ```sh
 * $ pulumi import gcp:compute/securityScanConfig:SecurityScanConfig default "{{project}} {{name}}"
 * ```
 *
 * ```sh
 * $ pulumi import gcp:compute/securityScanConfig:SecurityScanConfig default {{name}}
 * ```
 */
class SecurityScanConfig extends pulumi.CustomResource {
    /**
     * Get an existing SecurityScanConfig 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 SecurityScanConfig(name, state, { ...opts, id: id });
    }
    /**
     * Returns true if the given object is an instance of SecurityScanConfig.  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'] === SecurityScanConfig.__pulumiType;
    }
    constructor(name, argsOrState, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (opts.id) {
            const state = argsOrState;
            resourceInputs["authentication"] = state?.authentication;
            resourceInputs["blacklistPatterns"] = state?.blacklistPatterns;
            resourceInputs["displayName"] = state?.displayName;
            resourceInputs["exportToSecurityCommandCenter"] = state?.exportToSecurityCommandCenter;
            resourceInputs["maxQps"] = state?.maxQps;
            resourceInputs["name"] = state?.name;
            resourceInputs["project"] = state?.project;
            resourceInputs["schedule"] = state?.schedule;
            resourceInputs["startingUrls"] = state?.startingUrls;
            resourceInputs["targetPlatforms"] = state?.targetPlatforms;
            resourceInputs["userAgent"] = state?.userAgent;
        }
        else {
            const args = argsOrState;
            if (args?.displayName === undefined && !opts.urn) {
                throw new Error("Missing required property 'displayName'");
            }
            if (args?.startingUrls === undefined && !opts.urn) {
                throw new Error("Missing required property 'startingUrls'");
            }
            resourceInputs["authentication"] = args?.authentication;
            resourceInputs["blacklistPatterns"] = args?.blacklistPatterns;
            resourceInputs["displayName"] = args?.displayName;
            resourceInputs["exportToSecurityCommandCenter"] = args?.exportToSecurityCommandCenter;
            resourceInputs["maxQps"] = args?.maxQps;
            resourceInputs["project"] = args?.project;
            resourceInputs["schedule"] = args?.schedule;
            resourceInputs["startingUrls"] = args?.startingUrls;
            resourceInputs["targetPlatforms"] = args?.targetPlatforms;
            resourceInputs["userAgent"] = args?.userAgent;
            resourceInputs["name"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        super(SecurityScanConfig.__pulumiType, name, resourceInputs, opts);
    }
}
exports.SecurityScanConfig = SecurityScanConfig;
/** @internal */
SecurityScanConfig.__pulumiType = 'gcp:compute/securityScanConfig:SecurityScanConfig';
//# sourceMappingURL=securityScanConfig.js.map