Updated on 2024-12-10 GMT+08:00

Querying AZ Information

Function

This API is used to query the availability zone (AZ) ID used when you create a cluster.

URI

GET /v1.1/{region_id}/available-zones

Table 1 URI parameters

Parameter

Mandatory

Type

Description

region_id

Yes

String

Explanation

Region ID

Constraints

N/A

Value range

The value can contain 1 to 255 characters.

Default value

N/A

Table 2 Query parameters

Parameter

Mandatory

Type

Description

scope

No

String

Explanation

AZ scope.

Constraints

N/A

Value range

  • Center: central AZ
  • Edge: edge AZ

Default value

N/A

Request Parameters

None

Response Parameters

Status code: 200

Table 3 Response body parameter

Parameter

Type

Description

available_zones

Array of AvailableZoneV2 objects

Explanation

AZ list. For details about AvailableZoneV2, see Table 4.

Constraints

N/A

Value range

N/A

Default value

N/A

default_az_code

String

Explanation

Default AZ code

Constraints

N/A

Value range

N/A

Default value

N/A

support_physical_az_group

Boolean

Explanation

Whether physical AZ group is supported.

Constraints

N/A

Value range

  • True: Physical availability groups are supported.
  • False: Physical availability groups are not supported.

Default value

N/A

Table 4 AvailableZoneV2

Parameter

Type

Description

id

String

Explanation

ID

Constraints

N/A

Value range

N/A

Default value

N/A

az_code

String

Explanation

AZ code.

Constraints

N/A

Value range

N/A

Default value

N/A

az_name

String

Explanation

AZ name.

Constraints

N/A

Value range

N/A

Default value

N/A

az_id

String

Explanation

AZ ID.

Constraints

N/A

Value range

N/A

Default value

N/A

status

String

Explanation

AZ status

Constraints

N/A

Value range

N/A

Default value

N/A

region_id

String

Explanation

Region ID.

Constraints

N/A

Value range

N/A

Default value

N/A

az_group_id

String

Explanation

AZ group ID.

Constraints

N/A

Value range

N/A

Default value

N/A

az_type

String

Explanation

AZ type.

Constraints

N/A

Value range

  • Core
  • Satellite
  • Dedicated
  • Virtual
  • Edge
  • EdgeCental: central and edge

Default value

N/A

az_tags

AvailableTag object

Explanation

AZ tag. For details about AvailableTag, see Table 5.

Constraints

N/A

Value range

N/A

Default value

N/A

Table 5 AvailableTag

Parameter

Type

Description

mode

String

Explanation

Resource mode, which can be dedicated or shared.

Constraints

N/A

Value range

  • dedicated: dedicated AZ.
  • shared: shared AZ.

Default value

N/A

alias

String

Explanation

Alias of an AZ.

Constraints

N/A

Value range

N/A

Default value

N/A

public_border_group

String

Explanation

Group to which the AZ belongs. The default value is center.

Constraints

N/A

Value range

N/A

Default value

N/A

Example Request

None

Example Response

Status code: 200

Query AZ information.

{
  "available_zones" : [ {
    "id" : "xxx",
    "az_code" : "xxx",
    "az_name" : "AZ 1",
    "az_id" : "xxx",
    "status" : "Running",
    "region_id" : "xxx",
    "az_type" : "Dedicated",
    "az_group_id" : "",
    "az_tags" : {
      "mode" : null,
      "alias" : null,
      "public_border_group" : "center"
    }
  }, {
    "id" : "xxx",
    "az_code" : "xxx",
    "az_name" : "AZ 2",
    "az_id" : "xxx",
    "status" : "Running",
    "region_id" : "xxx",
    "az_type" : "Dedicated",
    "az_tags" : {
      "mode" : null,
      "alias" : null,
      "public_border_group" : "center"
    }
  }, {
    "id" : "xxx",
    "az_code" : "xxx",
    "az_name" : "AZ 3",
    "az_id" : "xxx",
    "status" : "Running",
    "region_id" : "xxx",
    "az_type" : "Dedicated",
    "az_tags" : {
      "mode" : null,
      "alias" : null,
      "public_border_group" : "center"
    }
  } ],
  "default_az_code" : "xxx",
  "support_physical_az_group" : true
}

Status Code

See Table 6.

Table 6 Status Code

Status Code

Description

200

AZ information

See Status Codes.

Error Codes

See Error Codes.