All Products
Search
Document Center

Expenses and Costs:InquiryPriceRefundInstance

Last Updated:Sep 01, 2026

Queries the refund amount for an instance that you want to unsubscribe from.

Operation description

  1. Carefully verify the information about the resource to be unsubscribed, and confirm the unsubscription terms and refund amount. Resources cannot be recovered after unsubscription.

  2. Only the actual paid amount is refunded. Used vouchers are not refunded.

  3. For other questions, refer to: Refund rules for Alibaba Cloud International Website

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

bss:RefundQueryRemainAmount

get

*All Resource

*

None None

Request parameters

Parameter

Type

Required

Description

Example

ClientToken

string

No

Required for idempotent scenarios. A UUID-generated string. This field is used for idempotence. If the same value is passed in multiple calls, the result of the first call is returned.

793F021C-B589-1225-82A9-99232AEBE494

ProductCode

string

No

Required for unsubscription scenarios. The product code.

ecs

InstanceId

string

No

Required for unsubscription scenarios. The instance ID.

i-bp1etb69sqxgl4*******

ProductType

string

No

Required for unsubscription scenarios. The product type. Pass an empty string ("") unless otherwise specified.

”“

Response elements

Element

Type

Description

Example

object

result

Message

string

The description of the execution result.

success

RequestId

string

The Tracing Analysis character string for the execute operation. You can provide this string to the platform for troubleshooting.

UUID

Data

object

data

HostId

string

The site where the execution host resides.

cn

InstanceId

string

The instance ID.

i-bp1etb69sqxgl4*******

Currency

string

The currency.

The currency of the refund amount: CNY: Chinese Yuan. USD: US Dollar. JPY: Japanese Yen

RefundAmount

number

The refund amount.

12.34

Code

string

The response code.

200

Success

boolean

Indicates whether the call is successful. A value of true indicates that the call is complete. A value of false indicates that an error occurred.

true

Examples

Success response

JSON format

{
  "Message": "success",
  "RequestId": "UUID",
  "Data": {
    "HostId": "cn",
    "InstanceId": "i-bp1etb69sqxgl4*******",
    "Currency": "CNY. CNY: Chinese Yuan. USD: United States dollar. JPY: Japanese Yen.",
    "RefundAmount": 12.34
  },
  "Code": "200",
  "Success": true
}

Error codes

HTTP status code

Error code

Error message

Description

400 ResourceNotExists The specific resource is not exists.
400 ResourceStatusError The resource status error.
400 InvalidOwner The specified owner does not belong to caller.
400 InvalidParameter The specified request contains invalid parameters.
400 MissingParameter The specified request lacks essential parameters.
400 NotApplicable The specified API is not applicable for the user.
400 NotAuthorized The user is not authorized for the specified API.
400 BindMirrorInstanceError Charged images that are related to ECS.
400 ExceedRefundQuotaError The number of unsubscription times has reached the upper limit.
400 ExistUnPaidOrderError The instance has an unsettled order.
400 ExistRefundingOrderError The instance ID is invalid: the instance may have expired, been refunded, or been released.
400 NoRestValueError The refund amount is 0.
400 AmbassadorOrderLimitError The instance has an ambassador order that may raise risks.
400 ActivityForbiddenError Promotional orders do not support refunds.
400 ProductCheckError The cloud service failed SPI preflight verification.
400 CommodityNotSupported The specified commodity is not supported.
500 InternalError An error occurred in the internal server. System exception, please try again

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.