Domain name for API request: cbs.intl.tencentcloudapi.com.
This API (DescribeDisks) is used to query the list of cloud disks.
Filter.Limit; the default is 20) of cloud disk lists are returned to the current user.A maximum of 100 requests can be initiated per second for this API.
The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.
| Parameter Name | Required | Type | Description |
|---|---|---|---|
| Action | Yes | String | Common Params. The value used for this API: DescribeDisks. |
| Version | Yes | String | Common Params. The value used for this API: 2017-03-12. |
| Region | Yes | String | Common Params. For more information, please see the list of regions supported by the product. |
| Filters.N | No | Array of Filter | Filters. You cannot specify DiskIds and Filters at the same time. |
| Limit | No | Integer | Number of results to be returned. Default is 20. Maximum is 100. For more information on disk-11112222, please see relevant sections in API Introduction. |
| OrderField | No | String | Field on which the list of cloud disks is sorted. valid values: sort by creation TIME by default. |
| Offset | No | Integer | Offset. Default is 0. For more information on tag-key, please see relevant sections in API Introduction. |
| ReturnBindAutoSnapshotPolicy | No | Boolean | Whether the ID of the periodic snapshot policy bound to the cloud disk needs to be returned in the cloud disk details. TRUE: return; FALSE: do not return. |
| DiskIds.N | No | Array of String | Query by one or more cloud disk IDs, such as Limit. For the format of this parameter, please see the ids.N section of the API Introduction. This parameter does not support specifying both Offset and disk-11112222. |
| Order | No | String | Specifies the sorting order of the cloud disk list. valid values: |
| Parameter Name | Type | Description |
|---|---|---|
| TotalCount | Integer | The quantity of cloud disks meeting the conditions. |
| DiskSet | Array of Disk | List of cloud disk details. |
| RequestId | String | The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. |
This example shows you how to query all mounted data disks.
POST / HTTP/1.1
Host: cbs.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeDisks
<Common request parameters>
{
"Filters": [
{
"Values": [
"ATTACHED"
],
"Name": "disk-state"
},
{
"Values": [
"DATA_DISK"
],
"Name": "disk-usage"
}
]
}
{
"Response": {
"TotalCount": 1,
"RequestId": "e2386a23-48c1-4c18-9a36-4e7354f333b2",
"DiskSet": [
{
"DeleteWithInstance": false,
"Encrypt": false,
"DiskType": "CLOUD_BSSD",
"AutoRenewFlagError": false,
"Rollbacking": false,
"RenewFlag": "NOTIFY_AND_MANUAL_RENEW",
"DiskName": "my-data-disk",
"Tags": [],
"InstanceId": "",
"DifferDaysOfDeadline": 1,
"DiskId": "disk-b94t5dzt",
"DiskState": "ATTACHED",
"Placement": {
"ProjectId": 0,
"Zone": "ap-guangzhou-3",
"ProjectName": "Default Project",
"CageId": "cage-bdq5l1mx",
"CdcName": "my-cloud-dedicated-cbs",
"CdcId": "cdc-1648zauv",
"DedicatedClusterId": "cluster-o42khj98"
},
"IsReturnable": false,
"DeadlineTime": "2018-10-26 10:55:43",
"Attached": true,
"DiskSize": 10,
"DiskUsage": "DATA_DISK",
"Portable": true,
"DiskChargeType": "PREPAID",
"SnapshotAbility": true,
"DeadlineError": false,
"RollbackPercent": 100,
"AutoSnapshotPolicyIds": null,
"ReturnFailCode": 3,
"CreateTime": "2018-09-26 17:36:07",
"ThroughputPerformance": 1,
"Migrating": true,
"InstanceIdList": [
"ins-agp4l0lx"
],
"Shareable": true,
"MigratePercent": 100,
"SnapshotSize": 100,
"SnapshotCount": 0,
"BackupDisk": true,
"AttachMode": "PF",
"DiskBackupQuota": 1,
"DiskBackupCount": 1,
"DeleteSnapshot": 0,
"InstanceType": "CVM",
"BurstPerformance": false,
"ErrorPrompt": "Detach disk timeout, please retry later",
"LastAttachInsId": "ins-agp4l0lx"
}
]
}
}
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.
The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.
| Error Code | Description |
|---|---|
| InvalidFilter | The specified Filter is not supported. |
| InvalidParameterValue | Invalid parameter value. |
| MissingParameter | Missing parameter. |
| UnsupportedOperation | Unsupported operation |
피드백