You can call DeleteInstance to release an ApsaraDB for Redis instance.

For more information about how to perform the corresponding operation in the console, see Release an instance.

Before you call this operation, make sure that the following requirements are met:

  • The instance is in the running state.
  • The instance is charged on a pay-as-you-go basis.
Note You cannot call this operation to release a subscription instance, which is automatically released when it expires. If you want to release a subscription instance before it expires, submit a ticket.

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 parameters

Parameter Type Required Example Description
Action String No DeleteInstance

The operation that you want to perform. Set the value to DeleteInstance.

InstanceId String Yes r-j6cxxxxxxxxxxxxx

The ID of the instance to be released.

Response parameters

Parameter Type Example Description
RequestId String 8D0C0AFC-E9CD-47A4-8395-5C31BF9B3E76

The ID of the request.

Examples

Sample requests

https://r-kvstore.aliyuncs.com/
?Action=DeleteInstance
&InstanceId=r-j6cxxxxxxxxxxxxx
&<Common request parameters>

Sample success responses

XML format

<DeleteInstanceResponse>
      <RequestId>8D0C0AFC-E9CD-47A4-8395-5C31BF9B3E76</RequestId>
</DeleteInstanceResponse>

JSON format

{
    "RequestId": "8D0C0AFC-E9CD-47A4-8395-5C31BF9B3E76"
}

Error codes

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