Call InterruptElasticsearchTask to interrupt the Alibaba cloud elasticsearch instance in the change. This parameter is valid only for instances in the initializing state. When the instance is interrupted, it enters the suspended state.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request header

This operation uses common request parameters only. For more information, see Common parameters.

Request syntax

POST /openapi/instances/[InstanceId]/actions/interrupt HTTPS|HTTP

Request parameters

Parameter Type Required Example Description
InstanceId String Yes es-cn-n6w1o1x0w001c****

The ID of the instance.

clientToken String No 5A2CFF0E-5718-45B5-9D4D-70B3FF****

A unique token generated by the client to guarantee the idempotency of the request. You can use the client to generate the value, but you must ensure that it is unique among different requests. The token can only contain ASCII characters and cannot exceed 64 characters in length.

Response parameters

Parameter Type Example Description
Code String InstanceStatusNotSupportCurrentAction

The error code. Only displayed if an exception is returned.

Message String The cluster is running tasks or in an error status. Try again later.

The error message. Only displayed if an exception is returned.

RequestId String 5FFD9ED4-C2EC-4E89-B22B-1ACB6FE1D****

The ID of the request.

Result Boolean true

Return results:

  • true: interrupted change successfully
  • false: interrupted change failed

Examples

Sample requests

POST /openapi/instances/es-cn-n6w1o1x0w001c****/actions/interrupt HTTP/1.1
Common request header

Sample success responses

XML format

<Result>true</Result>
<RequestId>E9908D15-13F4-4428-B08F-A3EE8E39****</RequestId>

JSON format

{
    "Result": true,
    "RequestId": "E9908D15-13F4-4428-B08F-A3EE8E39****"
}

Error codes

HttpCode Error code Error message Description
400 InstanceNotFound The instanceId provided does not exist. The error message returned because the specified instance cannot be found. Check the instance status.

For a list of error codes, visit the API Error Center.