AWS SDK Version 3 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

Container for the parameters to the InviteAccountToOrganization operation. Sends an invitation to another account to join your organization as a member account. Organizations sends email on your behalf to the email address that is associated with the other account's owner. The invitation is implemented as a Handshake whose details are in the response.

You can invite AWS accounts only from the same seller as the master account. For example, if your organization's master account was created by Amazon Internet Services Pvt. Ltd (AISPL), an AWS seller in India, then you can only invite other AISPL accounts to your organization. You can't combine accounts from AISPL and AWS, or any other AWS seller. For more information, see Consolidated Billing in India.

This operation can be called only from the organization's master account.

If you get an exception that indicates that you exceeded your account limits for the organization or that you can"t add an account because your organization is still initializing, please contact AWS Customer Support.

Inheritance Hierarchy

System.Object
  Amazon.Runtime.AmazonWebServiceRequest
    Amazon.Organizations.AmazonOrganizationsRequest
      Amazon.Organizations.Model.InviteAccountToOrganizationRequest

Namespace: Amazon.Organizations.Model
Assembly: AWSSDK.Organizations.dll
Version: 3.x.y.z

Syntax

C#
public class InviteAccountToOrganizationRequest : AmazonOrganizationsRequest
         IAmazonWebServiceRequest

The InviteAccountToOrganizationRequest type exposes the following members

Constructors

Properties

NameTypeDescription
Public Property Notes System.String

Gets and sets the property Notes.

Additional information that you want to include in the generated email to the recipient account owner.

Public Property Target Amazon.Organizations.Model.HandshakeParty

Gets and sets the property Target.

The identifier (ID) of the AWS account that you want to invite to join your organization. This is a JSON object that contains the following elements:

{ "Type": "ACCOUNT", "Id": "<account id number>" }

If you use the AWS CLI, you can submit this as a single string, similar to the following example:

--target Id=123456789012,Type=ACCOUNT

If you specify "Type": "ACCOUNT", then you must provide the AWS account ID number as the Id. If you specify "Type": "EMAIL", then you must specify the email address that is associated with the account.

--target Id=bill@example.com,Type=EMAIL

Examples

The following example shows the admin of the master account owned by bill@example.com inviting the account owned by juan@example.com to join an organization.

To invite an account to join an organization


var response = client.InviteAccountToOrganization(new InviteAccountToOrganizationRequest 
{
    Notes = "This is a request for Juan's account to join Bill's organization",
    Target = new HandshakeParty {
        Id = "juan@example.com",
        Type = "EMAIL"
    }
});

Handshake handshake = response.Handshake;

            

Version Information

.NET Standard:
Supported in: 1.3

.NET Framework:
Supported in: 4.5, 4.0, 3.5

Portable Class Library:
Supported in: Windows Store Apps
Supported in: Windows Phone 8.1
Supported in: Xamarin Android
Supported in: Xamarin iOS (Unified)
Supported in: Xamarin.Forms