Queries the stock keeping units (SKUs) of a service. In most cases, a service has one or more SKUs. A service may even have tens of thousands of SKUs. You can call this operation to query the SKUs of a specific service and the prices of the SKUs. You can configure request parameters to query the specified SKUs based on the configurations of the SKUs.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
bss:DescribeProduct | Read |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
CommodityCode | string | Yes | The code of the service. | ecs |
PriceEntityCode | string | Yes | The code of the pricing object. | instance_type |
PageSize | integer | Yes | The number of entries to be returned on each page. Maximum value: 50. | 20 |
NextPageToken | string | No | The token that is used to retrieve the next page. You do not need to set this parameter if you query coverage details for the first time. The response returns a token that you can use to query coverage details of the next page. If a null value is returned for the NextPageToken parameter, no more coverage details can be queried. | 080112060a0422020800180022490a470342000000315333303332363436363336333433393636333136333338333733373333333133373336363336323634363336363337333836333636333636313336363433363332 |
PriceFactorConditionMap | object | No | The conditions of the pricing factors. | |
array | No | The values of the pricing factors. | ||
string | No | The key-value pair of the pricing factor. | {"vm_region_no":"cn-shiwei-shenshu"} |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "F5B803CF-94D8-43AF-ADB3-D819AAD30E27",
"Code": "Success",
"Message": "Successful!",
"Success": true,
"Data": {
"SkuPricePage": {
"TotalCount": 18732,
"NextPageToken": "080112060a0422020800180022490a470342000000315333303332363436363336333433393636333136333338333733373333333133373336363336323634363336363337333836333636333636313336363433363332",
"SkuPriceList": [
{
"SkuCode": "017c15a31507bc6de22aa93777461adc",
"CskuPriceList": [
{
"CskuCode": "ac74dd7b52ae6389ddef099283fb8275",
"Currency": "CNY",
"UsageUnit": "Count\n",
"PriceType": "hourPrice",
"PriceMode": "STEP_ARRIVE",
"Price": "100",
"PriceUnit": "USD (per unit)\n",
"RangeList": [
{
"FactorCode": "212fbd27866307fc79ecf06934a88b2c",
"Min": "1",
"Max": "10",
"Type": "LORC"
}
]
}
],
"SkuFactorMap": {
"key": "{\"vm_region_no\",\"cn-qingdao-nebula\"}"
}
}
]
}
}
}
Error codes
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation | ||||
---|---|---|---|---|---|---|
2023-09-04 | The request parameters of the API has changed | see changesets | ||||
|