DescribeBudgetPolicies

Updated at:
Copy as MD

Queries cost budget policies.

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

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request syntax

POST  HTTP/1.1

Request parameters

Parameter

Type

Required

Description

Example

BudgetPolicyId

string

No

The budget policy ID.

023aacc1effc4b56bb154bfbec6baxxx

PageSize

integer

No

The number of entries per page. Valid values:

  • 30

  • 50

  • 100

Default value: 30.

30

PageNumber

integer

No

The page number.

1

GwClusterId

string

Yes

The gateway instance ID.

pg-xxxxxxx

Status

string

No

The policy status. Valid values:

  • Enabled: enabled

  • Disenabled: disabled

Enabled

BudgetDimensionType

string

No

The policy type. Valid values:

  • ConsumerGroup: total budget for a user group

  • Consumer: total budget for a user

ConsumerGroup

BudgetDimensionRefId

string

No

The dimension object ID. This parameter is required when BudgetDimensionType is set to ConsumerGroup or Consumer.

cg-p3gk2oh55c**

RegionId

string

No

The region ID.

cn-beijing

Response elements

Element

Type

Description

Example

object

Schema of Response

RequestId

string

Id of the request

24A1990B-4F6E-482B-B8CB-75C612******

TotalRecordCount

integer

The total number of records.

2

PageRecordCount

integer

The number of records on the current page.

1

PageNumber

integer

The page number.

1

PageSize

integer

The number of entries per page. Valid values: 30, 50, and 100.

Default value: 30.

30

Items

array<object>

The list of budget policies.

object

The budget policy object.

BudgetPolicyId

string

The budget policy ID.

023aacc1effc4b56bb154bfbec6ba9**

GwClusterId

string

The gateway instance ID.

pg-xxxxxxxx

Status

string

The policy status. Valid values:

  • Enabled: enabled

  • Disenabled: disabled

Enabled

BudgetType

string

The budget type. Valid values:

  • GlobalTotal: global total budget

  • ConsumerTotal: total budget for a user

  • ConsumerGroupTotal: total budget for a user group

GlobalTotal

BudgetDimensionType

string

The policy type. Valid values:

  • ConsumerGroup: total budget for a user group

  • Consumer: total budget for a user

ConsumerGroup

BudgetDimensionRefId

string

The dimension object ID. This parameter is required when BudgetDimensionType is set to ConsumerGroup or Consumer.

cg-p3gk2oh55c**

ResetDayOfMonth

string

The day of the month on which the budget resets. Valid values: 1 to 28.

2

BudgetPoints

string

The budget points.

10000

AlertThresholdPct

string

The alert threshold percentage. Valid values: 0 to 100.

80

UsedPoints

integer

The number of used points.

10

GmtCreated

string

The time when the policy was created.

2025-03-19T14:13:53+08:00

GmtModified

string

The time when the policy was last modified.

2025-04-08T10:43:28+08:00

AlertTriggered

boolean

Indicates whether the alert threshold has been triggered.

false

Exceeded

string

Indicates whether the quota has been exceeded.

false

Examples

Success response

JSON format

{
  "RequestId": "24A1990B-4F6E-482B-B8CB-75C612******",
  "TotalRecordCount": 2,
  "PageRecordCount": 1,
  "PageNumber": 1,
  "PageSize": 30,
  "Items": [
    {
      "BudgetPolicyId": "023aacc1effc4b56bb154bfbec6ba9**",
      "GwClusterId": "pg-xxxxxxxx",
      "Status": "Enabled",
      "BudgetType": "GlobalTotal",
      "BudgetDimensionType": "ConsumerGroup ",
      "BudgetDimensionRefId": "cg-p3gk2oh55c**",
      "ResetDayOfMonth": "2",
      "BudgetPoints": "10000",
      "AlertThresholdPct": "80",
      "UsedPoints": 10,
      "GmtCreated": "2025-03-19T14:13:53+08:00",
      "GmtModified": "2025-04-08T10:43:28+08:00",
      "AlertTriggered": false,
      "Exceeded": "false"
    }
  ]
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.