UNPKG

@pulumi/aws

Version:

A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.

90 lines 4.33 kB
"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.LicenseGrantAccepter = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Accepts a License Manager grant. This allows for sharing licenses with other aws accounts. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const test = new aws.licensemanager.LicenseGrantAccepter("test", {grantArn: "arn:aws:license-manager::123456789012:grant:g-1cf9fba4ba2f42dcab11c686c4b4d329"}); * ``` * * ## Import * * Using `pulumi import`, import `aws_licensemanager_grant_accepter` using the grant arn. For example: * * ```sh * $ pulumi import aws:licensemanager/licenseGrantAccepter:LicenseGrantAccepter test arn:aws:license-manager::123456789012:grant:g-1cf9fba4ba2f42dcab11c686c4b4d329 * ``` */ class LicenseGrantAccepter extends pulumi.CustomResource { /** * Get an existing LicenseGrantAccepter 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 LicenseGrantAccepter(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of LicenseGrantAccepter. 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'] === LicenseGrantAccepter.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["allowedOperations"] = state ? state.allowedOperations : undefined; resourceInputs["grantArn"] = state ? state.grantArn : undefined; resourceInputs["homeRegion"] = state ? state.homeRegion : undefined; resourceInputs["licenseArn"] = state ? state.licenseArn : undefined; resourceInputs["name"] = state ? state.name : undefined; resourceInputs["parentArn"] = state ? state.parentArn : undefined; resourceInputs["principal"] = state ? state.principal : undefined; resourceInputs["region"] = state ? state.region : undefined; resourceInputs["status"] = state ? state.status : undefined; resourceInputs["version"] = state ? state.version : undefined; } else { const args = argsOrState; if ((!args || args.grantArn === undefined) && !opts.urn) { throw new Error("Missing required property 'grantArn'"); } resourceInputs["grantArn"] = args ? args.grantArn : undefined; resourceInputs["region"] = args ? args.region : undefined; resourceInputs["allowedOperations"] = undefined /*out*/; resourceInputs["homeRegion"] = undefined /*out*/; resourceInputs["licenseArn"] = undefined /*out*/; resourceInputs["name"] = undefined /*out*/; resourceInputs["parentArn"] = undefined /*out*/; resourceInputs["principal"] = undefined /*out*/; resourceInputs["status"] = undefined /*out*/; resourceInputs["version"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(LicenseGrantAccepter.__pulumiType, name, resourceInputs, opts); } } exports.LicenseGrantAccepter = LicenseGrantAccepter; /** @internal */ LicenseGrantAccepter.__pulumiType = 'aws:licensemanager/licenseGrantAccepter:LicenseGrantAccepter'; //# sourceMappingURL=licenseGrantAccepter.js.map