forked from docs/doc-exports
Reviewed-by: Pristromskaia, Margarita <margarita.pristromskaia@t-systems.com> Co-authored-by: wanghuijuan738 <wanghuijuan738@huawei.com> Co-committed-by: wanghuijuan738 <wanghuijuan738@huawei.com>
10 KiB
10 KiB
Querying AZs
Function
This API is used to list AZs.
URI
GET /v2.1/{project_id}/os-availability-zone
GET /v2/{project_id}/os-availability-zone
Table 1 describes the parameters in the URI.
Response
Table 2 describes the response parameters.
Parameter |
Type |
Description |
|---|---|---|
availabilityZoneInfo |
Array of objects |
Specifies the AZ information. For details, see Table 3. |
Parameter |
Type |
Description |
|---|---|---|
zoneState |
Object |
Specifies the AZ status. For details, see Table 4. |
hosts |
List |
The parameter is set to null. |
zoneName |
String |
Specifies the AZ name. |
Example Request
Query a list of AZs.
GET https://{endpoint}/v2/9c53a566cb3443ab910cf0daebca90c4/os-availability-zone
GET https://{endpoint}/v2.1/9c53a566cb3443ab910cf0daebca90c4/os-availability-zone
Example Response
{
"availabilityZoneInfo": [{
"zoneState": {
"available": true
},
"hosts": null,
"zoneName": "az1" //Replace the value with the actual AZ name.
},
{
"zoneState": {
"available": true
},
"hosts": null,
"zoneName": "az2" //Replace the value with the actual AZ name.
}]
}
Returned Values
Parent topic: AZ