UNPKG

@pulumi/aws

Version:

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

112 lines 4.87 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.Member = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Provides a resource to manage an [Amazon Macie Member](https://docs.aws.amazon.com/macie/latest/APIReference/members-id.html). * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const example = new aws.macie2.Account("example", {}); * const exampleMember = new aws.macie2.Member("example", { * accountId: "AWS ACCOUNT ID", * email: "EMAIL", * invite: true, * invitationMessage: "Message of the invitation", * invitationDisableEmailNotification: true, * }, { * dependsOn: [example], * }); * ``` * * ## Import * * Using `pulumi import`, import `aws_macie2_member` using the account ID of the member account. For example: * * ```sh * $ pulumi import aws:macie2/member:Member example 123456789012 * ``` */ class Member extends pulumi.CustomResource { /** * Get an existing Member 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 Member(name, state, { ...opts, id: id }); } /** * Returns true if the given object is an instance of Member. 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'] === Member.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["accountId"] = state?.accountId; resourceInputs["administratorAccountId"] = state?.administratorAccountId; resourceInputs["arn"] = state?.arn; resourceInputs["email"] = state?.email; resourceInputs["invitationDisableEmailNotification"] = state?.invitationDisableEmailNotification; resourceInputs["invitationMessage"] = state?.invitationMessage; resourceInputs["invite"] = state?.invite; resourceInputs["invitedAt"] = state?.invitedAt; resourceInputs["masterAccountId"] = state?.masterAccountId; resourceInputs["region"] = state?.region; resourceInputs["relationshipStatus"] = state?.relationshipStatus; resourceInputs["status"] = state?.status; resourceInputs["tags"] = state?.tags; resourceInputs["tagsAll"] = state?.tagsAll; resourceInputs["updatedAt"] = state?.updatedAt; } else { const args = argsOrState; if (args?.accountId === undefined && !opts.urn) { throw new Error("Missing required property 'accountId'"); } if (args?.email === undefined && !opts.urn) { throw new Error("Missing required property 'email'"); } resourceInputs["accountId"] = args?.accountId; resourceInputs["email"] = args?.email; resourceInputs["invitationDisableEmailNotification"] = args?.invitationDisableEmailNotification; resourceInputs["invitationMessage"] = args?.invitationMessage; resourceInputs["invite"] = args?.invite; resourceInputs["region"] = args?.region; resourceInputs["status"] = args?.status; resourceInputs["tags"] = args?.tags; resourceInputs["administratorAccountId"] = undefined /*out*/; resourceInputs["arn"] = undefined /*out*/; resourceInputs["invitedAt"] = undefined /*out*/; resourceInputs["masterAccountId"] = undefined /*out*/; resourceInputs["relationshipStatus"] = undefined /*out*/; resourceInputs["tagsAll"] = undefined /*out*/; resourceInputs["updatedAt"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(Member.__pulumiType, name, resourceInputs, opts); } } exports.Member = Member; /** @internal */ Member.__pulumiType = 'aws:macie2/member:Member'; //# sourceMappingURL=member.js.map