Querying AZ Information
Function
This API is used to query AZ information.
Calling Method
For details, see Calling APIs.
URI
GET /v2/{project_id}/dbss/audit/availability-zone
| Parameter | Mandatory | Parameter Type | Description |
|---|---|---|---|
| project_id | Yes | String | Project ID. |
Request Parameter
| Parameter | Mandatory | Parameter Type | Description |
|---|---|---|---|
| X-Auth-Token | Yes | String | User token. The token can be queried by calling the IAM API. (The token is the value of X-Subject-Token in the response header.) |
Response Parameters
Status code: 200
| Parameter | Parameter Type | Description |
|---|---|---|
| azs | Array of AzInfo objects | AZ set |
| Parameter | Parameter Type | Description |
|---|---|---|
| zone_name | String | AZ name |
| zone_number | Integer | AZ number |
| az_type | String | AZ type |
| alias | String | Chinese alias of the AZ |
| alias_us | String | English alias of the AZ |
Status code: 400
| Parameter | Parameter Type | Description |
|---|---|---|
| error | Object | Error message. |
| Parameter | Parameter Type | Description |
|---|---|---|
| error_code | String | Error code |
| error_msg | String | Error message |
Status code: 403
| Parameter | Parameter Type | Description |
|---|---|---|
| error | Object | Error message. |
| Parameter | Parameter Type | Description |
|---|---|---|
| error_code | String | Error code |
| error_msg | String | Error message |
Status code: 500
| Parameter | Parameter Type | Description |
|---|---|---|
| error | Object | Error message. |
| Parameter | Parameter Type | Description |
|---|---|---|
| error_code | String | Error code |
| error_msg | String | Error message |
Example Request
/v2/{project_id}/dbss/audit/availability-zone Example Response
Status code: 200
Succeeded
{
"azs" : [ {
"zone_name" : "xx-xx",
"zone_number" : 2,
"az_type" : "normal",
"alias" : "AZ 2",
"alias_us" : "AZ2"
}, {
"zone_name" : "xx-xx",
"zone_number" : 1,
"az_type" : "normal",
"alias" : "AZ 1",
"alias_us" : "AZ1"
}, {
"zone_name" : "xx-xx",
"zone_number" : 3,
"az_type" : "normal",
"alias" : "AZ 3",
"alias_us" : "AZ3"
} ]
} Status code: 400
Client errors
{
"error" : {
"error_code" : "DBSS.XXXX",
"error_msg" : "XXX"
}
} Status Code
| Status Code | Description |
|---|---|
| 200 | Success |
| 400 | Client errors |
| 403 | Authentication failed. |
| 500 | Server error. |
Error Codes
For details, see Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.