fbpx
POSThttps://api.spotinst.io/aws/ec2/instance/signal?accountId={ACCOUNT_ID}

The instance signal API is used for notifying Spotinst about the instance state, so Spotinst can act accordingly. Supported signals are: INSTANCE_READY – Whenever this signal is sent, Spotinst will register the instance to the ELB INSTANCE_READY_TO_SHUTDOWN – Whenever this signal is sent, Spotinst will terminate the instance after it was marked for termination.

Important: You need to define the expected signals for your Elastigroup in the group configuration.

Body Attributes


Attribute Type Description
instanceId * String

The instance ID the signal refers to.

signal * String

The specific signal you want to trigger. Valid Values: INSTANCE_READY, INSTANCE_READY_TO_SHUTDOWN

ACCOUNT_ID String

Your Spotinst accountId associated with your token

Example: act-123abc
Request

Headers
{
    "Content-Type": "application/json",
    "Authorization": "Bearer ${token}"
}
Body
Copied!
Downloaded!
{
  "instanceId": "i-123456",
  "signal": "INSTANCE_READY"
}
Response - 200

Headers
{
    "Content-Type": "application/json"
}
Body
Copied!
Downloaded!
{
  "request": {
    "id": "3213e42e-455e-4901-a185-cc3eb65fac5f",
    "url": "/aws/ec2/instance/signal",
    "method": "POST",
    "time": "2016-02-10T15:49:11.911Z"
  },
  "response": {
    "status": {
      "code": 200,
      "message": "OK"
    }
  }
}