| « PreviousNext » | |
![]() ![]() | Did this page help you? Yes | No | Tell us about it... |
Cancels one or more Spot Instance requests. Spot Instances are instances that Amazon EC2 starts on your behalf when the maximum price that you specify exceeds the current Spot Price. Amazon EC2 periodically sets the Spot Price based on available Spot Instance capacity and current Spot Instance requests. For more information about Spot Instances, see Spot Instances in the Amazon Elastic Compute Cloud User Guide.
Important
Canceling a Spot Instance request does not terminate running Spot Instances associated with the request.
SpotInstanceRequestId.nOne or more Spot Instance request IDs.
Type: String
Default: None
Required: Yes
The following elements are returned in a
CancelSpotInstanceRequestsResponse element.
requestIdThe ID of the request.
Type: xsd:string
spotInstanceRequestSetA list of Spot Instance requests. Each request is wrapped
in an item element.
This example cancels a Spot Instance request.
https://ec2.amazonaws.com/?Action=CancelSpotInstanceRequests &SpotInstanceRequestId.1=sir-1a2b3c4d &AUTHPARAMS
<CancelSpotInstanceRequestsResponse xmlns="http://ec2.amazonaws.com/doc/2013-02-01/">
<requestId>59dbff89-35bd-4eac-99ed-be587EXAMPLE</requestId>
<spotInstanceRequestSet>
<item>
<spotInstanceRequestId>sir-1a2b3c4d</spotInstanceRequestId>
<state>cancelled</state>
</item>
</spotInstanceRequestSet></CancelSpotInstanceRequestsResponse>