POST /#Action=ModifyInstancePlacement

Modifies the placement attributes for a specified instance. You can do the following:

At least one attribute for affinity, host ID, tenancy, or placement group name must be specified in the request. Affinity and tenancy can be modified in the same request.

To modify the host ID, tenancy, placement group, or partition for an instance, the instance must be in the stopped state.

Servers

Request headers

Name Type Required Description
X-Amz-Content-Sha256 String No
X-Amz-Credential String No
Content-Type String Yes The media type of the request body.

Default value: "text/xml"

X-Amz-Date String No
X-Amz-Algorithm String No
X-Amz-SignedHeaders String No
X-Amz-Security-Token String No
X-Amz-Signature String No

Query parameters

Name Type Required Description
Version String Yes

Possible values:

  • "2016-11-15"
Action String Yes

Possible values:

  • "ModifyInstancePlacement"

Request body fields

Name Type Required Description
InstanceId String Yes

The ID of the instance that you are modifying.

HostResourceGroupArn String No

The ARN of the host resource group in which to place the instance.

GroupName String No

The name of the placement group in which to place the instance. For spread placement groups, the instance must have a tenancy of default. For cluster and partition placement groups, the instance must have a tenancy of default or dedicated.

To remove an instance from a placement group, specify an empty string ("").

Tenancy String No

The tenancy for the instance.

For T3 instances, you can't change the tenancy from dedicated to host, or from host to dedicated. Attempting to make one of these unsupported tenancy changes results in the InvalidTenancy error code.

Possible values:

  • "dedicated"
  • "host"
HostId String No

The ID of the Dedicated Host with which to associate the instance.

GroupId String No

The Group Id of a placement group. You must specify the Placement Group Group Id to launch an instance in a shared placement group.

Affinity String No

The affinity setting for the instance.

Possible values:

  • "host"
  • "default"
PartitionNumber Integer No

The number of the partition in which to place the instance. Valid only if the placement group strategy is set to partition.

How to start integrating

  1. Add HTTP Task to your workflow definition.
  2. Search for the API you want to integrate with and click on the name.
    • This loads the API reference documentation and prepares the Http request settings.
  3. Click Test request to test run your request to the API and see the API's response.