Updated on 2025-08-28 GMT+08:00

Querying Expenditure Quota

Function

An expenditure quota is the maximum expenditure amount that a customer using monthly settlement can spend on Huawei Cloud. It is not a payment method. You cannot use this quota for payment or as a basis for reconciliation or payment.

A customer can query their expenditure quota.

Expenditure quota is not available for customers associated with a partner in the reseller model. No results will be returned.

Constraints

When a customer queries their expenditure quota, only the AK/SK or token of the customer can be used.

Debugging

You can debug the API in API Explorer which supports automatic authentication. API Explorer can automatically generate and debug example SDK code.

URI

GET /v2/accounts/customer-accounts/expenditure-quota

Request

None

Example Request

GET https://bss-intl.myhuaweicloud.com/v2/accounts/customer-accounts/expenditure-quota HTTP/1.1
Content-Type: application/json
X-Auth-Token: MIIPAgYJKoZIhvcNAQcCo...ggg1BBIINPXsidG9rZ

Response

Response parameters

Parameter

Type

Maximum Length/Value Range

Description

error_code

String

A maximum of 20 characters

Error code. For details, see Returned Values.

This parameter is returned only when a failure occurs.

error_msg

String

A maximum of 2,000 characters

Error description.

This parameter is returned only when a failure occurs.

granting_amount

BigDecimal

-

Expenditure quota granted.

granting_amount_used

BigDecimal

  

Used expenditure quota.

percentage_granting_amount_used

BigDecimal

  

Percentage of the used expenditure quota.

Percentage = Used expenditure quota/Expenditure quota. The value is accurate to two decimal places. If the expenditure quota is 0, the percentage of the used expenditure quota is 0.

measure_id

Integer

-

Unit.

  • 1: Dollar

currency

String

A maximum of 4 characters

Currency. The options are as follows:

USD

Example Response
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: length
Date: response time  
{
    "granting_amount": 200.0,
    "granting_amount_used": 122.0,
    "percentage_granting_amount_used": 0.61,
    "measure_id": 1,
    "currency": "USD"
}

Status Codes

  • 4xx: This class of HTTP status code is intended for situations in which the error seems to have been caused by the client, for example, the request contains bad syntax or incorrect parameters. You must ensure the request is correct.
  • 5xx: This class of HTTP status code is intended for cases in which the Huawei Cloud server is aware that it has encountered an error or is otherwise incapable of performing the request. In this case, contact Huawei Cloud customer service.

HTTP Status Code

Error Code

Description

400

CBC.0100

Parameter error.

403

CBC.0151

Access denied.

500

CBC.0999

Other errors.