-
Notifications
You must be signed in to change notification settings - Fork 0
api.aws.ec2.stopInstances
tristanls edited this page Nov 25, 2012
·
3 revisions
Stop EC2 instances.
Since Version | 0.0.0 |
Scope | |
accepts: | public |
All parameters are optional, unless otherwise indicated.
awsAccessKeyId | AKIAIOSFODNN7EXAMPLE |
required AWS Access Key Id |
instanceIds | [ "i-aEXAMPLE", "i-bEXAMPLE" ] |
required EC2 instances to stop |
secretAccessKey | wJalrXUtnFEMI/K7MDENG+bPxRfiCYEXAMPLEKEY |
required AWS Secret Access Key |
force | true |
Forces the instances to stop |
securityToken | tnFEMI/K7MDtnFEMI/K7MDtnFEMI/K7MD |
security token to include in the request |
Single instance response.
requestId | b11c694a-6a7f-44a0-9439-feda01571000 |
AWS EC2 request id for idempotency guarantee |
reservationId | r-dEXAMPLE |
Reservation Id of launched instance |
ownerId | 12345EXAMPLE |
Owner Id of launched instance |
groupSet | {"item":{"groupId":"sg-eEXAMPLE... |
Groups of launched instance |
instancesSet | {"item":{INSTANCE}} |
Set of launched instance |
Multiple instances response.
requestId | b11c694a-6a7f-44a0-9439-feda01571000 |
AWS EC2 request id for idempotency guarantee |
reservationSet | {"item":[RESERVATION,RESERVATION] |
Launched instances (see RESERVATION below) |
{
"reservationId":"r-dEXAMPLE",
"ownerId":"12345EXAMPLE",
"groupSet":{
"item":{
"groupId":"sg-eEXAMPLE",
"groupName":"default"
}
},
"instancesSet":{
"item":[ INSTANCE, INSTANCE ]
}
}
{
"instanceId":"i-018bc87e",
"imageId":"ami-3d4ff254",
"instanceState":{
"code":"0",
"name":"stopping"
},
"amiLaunchIndex":"0",
"instanceType":"t1.micro",
"launchTime":"2012-11-25T17:37:41.000Z",
"placement":{
"availabilityZone":"us-east-1b",
"tenancy":"default"
},
"kernelId":"aki-825ea7eb",
"monitoring":{
"state":"disabled"
},
"groupSet":{
"item":{
"groupId":"sg-eEXAMPLE",
"groupName":"default"
}
},
"stateReason":{
"code":"stopping",
"message":"stopping"
},
"architecture":"x86_64",
"rootDeviceType":"ebs",
"rootDeviceName":"/dev/sda1",
"virtualizationType":"paravirtual",
"hypervisor":"xen",
"ebsOptimized":false
}
message | Error message |
Error message |
crosstalk.emit(
"~crosstalk.api.aws.ec2.stopInstances",
{
awsAccessKeyId : "KEYNAME",
instanceIds : [ "i-018bc87e" ],
secretAccessKey : "wJalrXUtnFEMI/K7MDENG+bPxRfiCYEXAMPLEKEY"
},
"~crosstalk",
function ( error, response ) { /* ... */ }
);
{
"requestId":"1970fe32-f1cd-48c6-abe3-3f8d41b31526",
"reservationId":"r-dEXAMPLE",
"ownerId":"12345EXAMPLE",
"groupSet":{
"item":{
"groupId":"sg-eEXAMPLE",
"groupName":"default"
}
},
"instancesSet":{
"item":{
"instanceId":"i-018bc87e",
"imageId":"ami-3d4ff254",
"instanceState":{
"code":"0",
"name":"stopping"
},
"amiLaunchIndex":"0",
"instanceType":"t1.micro",
"launchTime":"2012-11-25T17:37:41.000Z",
"placement":{
"availabilityZone":"us-east-1b",
"tenancy":"default"
},
"kernelId":"aki-825ea7eb",
"monitoring":{
"state":"disabled"
},
"groupSet":{
"item":{
"groupId":"sg-eEXAMPLE",
"groupName":"default"
}
},
"stateReason":{
"code":"stopping",
"message":"stopping"
},
"architecture":"x86_64",
"rootDeviceType":"ebs",
"rootDeviceName":"/dev/sda1",
"virtualizationType":"paravirtual",
"hypervisor":"xen",
"ebsOptimized":false
}
}
}
{
"message": "Error message"
}