"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.WorkspaceProductApiLink = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
 * Product-API link details.
 *
 * Uses Azure REST API version 2022-09-01-preview. In version 2.x of the Azure Native provider, it used API version 2022-09-01-preview.
 *
 * Other available API versions: 2023-03-01-preview, 2023-05-01-preview, 2023-09-01-preview, 2024-05-01, 2024-06-01-preview, 2024-10-01-preview. These can be accessed by generating a local SDK package using the CLI command `pulumi package add azure-native apimanagement [ApiVersion]`. See the [version guide](../../../version-guide/#accessing-any-api-version-via-local-packages) for details.
 */
class WorkspaceProductApiLink extends pulumi.CustomResource {
    /**
     * Get an existing WorkspaceProductApiLink 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 opts Optional settings to control the behavior of the CustomResource.
     */
    static get(name, id, opts) {
        return new WorkspaceProductApiLink(name, undefined, { ...opts, id: id });
    }
    /**
     * Returns true if the given object is an instance of WorkspaceProductApiLink.  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'] === WorkspaceProductApiLink.__pulumiType;
    }
    /**
     * Create a WorkspaceProductApiLink resource with the given unique name, arguments, and options.
     *
     * @param name The _unique_ name of the resource.
     * @param args The arguments to use to populate this resource's properties.
     * @param opts A bag of options that control this resource's behavior.
     */
    constructor(name, args, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (!opts.id) {
            if (args?.apiId === undefined && !opts.urn) {
                throw new Error("Missing required property 'apiId'");
            }
            if (args?.productId === undefined && !opts.urn) {
                throw new Error("Missing required property 'productId'");
            }
            if (args?.resourceGroupName === undefined && !opts.urn) {
                throw new Error("Missing required property 'resourceGroupName'");
            }
            if (args?.serviceName === undefined && !opts.urn) {
                throw new Error("Missing required property 'serviceName'");
            }
            if (args?.workspaceId === undefined && !opts.urn) {
                throw new Error("Missing required property 'workspaceId'");
            }
            resourceInputs["apiId"] = args?.apiId;
            resourceInputs["apiLinkId"] = args?.apiLinkId;
            resourceInputs["productId"] = args?.productId;
            resourceInputs["resourceGroupName"] = args?.resourceGroupName;
            resourceInputs["serviceName"] = args?.serviceName;
            resourceInputs["workspaceId"] = args?.workspaceId;
            resourceInputs["azureApiVersion"] = undefined /*out*/;
            resourceInputs["name"] = undefined /*out*/;
            resourceInputs["type"] = undefined /*out*/;
        }
        else {
            resourceInputs["apiId"] = undefined /*out*/;
            resourceInputs["azureApiVersion"] = undefined /*out*/;
            resourceInputs["name"] = undefined /*out*/;
            resourceInputs["type"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        const aliasOpts = { aliases: [{ type: "azure-native:apimanagement/v20220901preview:WorkspaceProductApiLink" }, { type: "azure-native:apimanagement/v20230301preview:WorkspaceProductApiLink" }, { type: "azure-native:apimanagement/v20230501preview:WorkspaceProductApiLink" }, { type: "azure-native:apimanagement/v20230901preview:WorkspaceProductApiLink" }, { type: "azure-native:apimanagement/v20240501:WorkspaceProductApiLink" }, { type: "azure-native:apimanagement/v20240601preview:WorkspaceProductApiLink" }, { type: "azure-native:apimanagement/v20241001preview:WorkspaceProductApiLink" }] };
        opts = pulumi.mergeOptions(opts, aliasOpts);
        super(WorkspaceProductApiLink.__pulumiType, name, resourceInputs, opts);
    }
}
exports.WorkspaceProductApiLink = WorkspaceProductApiLink;
/** @internal */
WorkspaceProductApiLink.__pulumiType = 'azure-native:apimanagement:WorkspaceProductApiLink';
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoid29ya3NwYWNlUHJvZHVjdEFwaUxpbmsuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9hcGltYW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