Amazon Elastic Compute Cloud
API Reference (API Version 2016-11-15)


Modify the auto-placement setting of a Dedicated Host. When auto-placement is enabled, AWS will place instances that you launch with a tenancy of host, but without targeting a specific host ID, onto any available Dedicated Host in your account which has auto-placement enabled. When auto-placement is disabled, you need to provide a host ID if you want the instance to launch onto a specific host. If no host ID is provided, the instance will be launched onto a suitable host which has auto-placement enabled.

Request Parameters

The following parameters are for this specific action. For more information about required and optional parameters that are common to all actions, see Common Query Parameters.


Specify whether to enable or disable auto-placement.

Type: String

Valid Values: on | off

Required: Yes


The host IDs of the Dedicated Hosts you want to modify.

Type: Array of strings

Required: Yes

Response Elements

The following elements are returned by the service.


The ID of the request.

Type: String


The IDs of the Dedicated Hosts that were successfully modified.

Type: Array of strings


The IDs of the Dedicated Hosts that could not be modified. Check whether the setting you requested can be used.

Type: Array of UnsuccessfulItem objects


For information about the errors that are common to all actions, see Common Client Errors.



This example enables the auto-placement setting on a Dedicated Host.

Sample Request &AutoPlacement=on &HostId=h-00548908djdsgfs &AUTHPARAMS

Sample Response

<ModifyHostsResponse xmlns=""> <requestId>d4904fd9-82c2-4ea5-adfe-a9cc3EXAMPLE</requestId> <unsuccessful/> <successful> <item>h-00548908djdsgfs</item> </successful> </ModifyHostsResponse>

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: