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 MoveAccount operation. Moves an account from its current source parent root or OU to the specified destination parent root or OU.

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

Inheritance Hierarchy

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

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

Syntax

C#
public class MoveAccountRequest : AmazonOrganizationsRequest
         IAmazonWebServiceRequest

The MoveAccountRequest type exposes the following members

Constructors

NameDescription
Public Method MoveAccountRequest()

Properties

NameTypeDescription
Public Property AccountId System.String

Gets and sets the property AccountId.

The unique identifier (ID) of the account that you want to move.

The regex pattern for an account ID string requires exactly 12 digits.

Public Property DestinationParentId System.String

Gets and sets the property DestinationParentId.

The unique identifier (ID) of the root or organizational unit that you want to move the account to.

The regex pattern for a parent ID string requires one of the following:

  • Root: a string that begins with "r-" followed by from 4 to 32 lower-case letters or digits.

  • Organizational unit (OU): a string that begins with "ou-" followed by from 4 to 32 lower-case letters or digits (the ID of the root that the OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case letters or digits.

Public Property SourceParentId System.String

Gets and sets the property SourceParentId.

The unique identifier (ID) of the root or organizational unit that you want to move the account from.

The regex pattern for a parent ID string requires one of the following:

  • Root: a string that begins with "r-" followed by from 4 to 32 lower-case letters or digits.

  • Organizational unit (OU): a string that begins with "ou-" followed by from 4 to 32 lower-case letters or digits (the ID of the root that the OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case letters or digits.

Examples

The following example shows how to move a member account from the root to an OU:/n/n

To move an OU or account to another OU or the root


var response = client.MoveAccount(new MoveAccountRequest 
{
    AccountId = "333333333333",
    DestinationParentId = "ou-examplerootid111-exampleouid111",
    SourceParentId = "r-examplerootid111"
});


            

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