Updated on 2024-11-07 GMT+08:00

Querying AZs

Function

This API is used to query AZs where you can buy gateways.

Calling Method

For details, see Calling APIs.

URI

GET /v2/{project_id}/apigw/available-zones

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID. For details about how to obtain it, see Obtaining a Project ID.

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token. It can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is a token.

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

available_zones

Array of AvailableZone objects

AZ list.

Table 4 AvailableZone

Parameter

Type

Description

name

String

AZ name.

id

String

Error message.

code

String

AZ code.

port

String

AZ port.

local_name

LocalName object

AZ names.

specs

Map<String,Boolean>

Gateway editions available in the AZ.

Table 5 LocalName

Parameter

Type

Description

en_us

String

AZ name.

zh_cn

String

AZ name.

Status code: 401

Table 6 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Status code: 403

Table 7 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Status code: 500

Table 8 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Example Requests

None

Example Responses

Status code: 200

OK

{
  "available_zones" : [ {
    "code" : "xx-xxx-4a",
    "id" : "effdcbc7d4d64a02aa1fa26b42f56533",
    "local_name" : {
      "en_us" : "AZ1",
      "zh_cn" : "<Name_of_AZ1>"
    },
    "name" : "<Name_of_AZ1>",
    "port" : "8403",
    "specs" : {
      "BASIC" : true,
      "BASIC_IPV6" : false,
      "ENTERPRISE" : true,
      "ENTERPRISE_IPV6" : false,
      "PLATINUM" : true,
      "PLATINUM_IPV6" : false,
      "PROFESSIONAL" : true,
      "PROFESSIONAL_IPV6" : false,
      "TRIAL" : true,
      "PLATINUM_X2" : false,
      "PLATINUM_X3" : false,
      "PLATINUM_X4" : false,
      "PLATINUM_X5" : false,
      "PLATINUM_X6" : false,
      "PLATINUM_X7" : false,
      "PLATINUM_X8" : false
    }
  }, {
    "code" : "xx-xxx-4b",
    "id" : "a0865121f83b41cbafce65930a22a6e8",
    "local_name" : {
      "en_us" : "AZ2",
      "zh_cn" : "<Name_of_AZ2>"
    },
    "name" : "<Name_of_AZ2>",
    "port" : "8404",
    "specs" : {
      "BASIC" : true,
      "BASIC_IPV6" : true,
      "ENTERPRISE" : true,
      "ENTERPRISE_IPV6" : true,
      "PLATINUM" : true,
      "PLATINUM_IPV6" : false,
      "PROFESSIONAL" : true,
      "PROFESSIONAL_IPV6" : true,
      "TRIAL" : true,
      "PLATINUM_X2" : false,
      "PLATINUM_X3" : false,
      "PLATINUM_X4" : false,
      "PLATINUM_X5" : false,
      "PLATINUM_X6" : false,
      "PLATINUM_X7" : false,
      "PLATINUM_X8" : false
    }
  } ]
}

Status code: 401

Unauthorized

{
  "error_code" : "APIC.7102",
  "error_msg" : "Incorrect token or token resolution failed"
}

Status code: 403

Forbidden

{
  "error_code" : "APIC.7106",
  "error_msg" : "No permissions to request for the method"
}

Status code: 500

Internal Server Error

{
  "error_code" : "APIC.9000",
  "error_msg" : "Failed to request internal service"
}

Status Codes

Status Code

Description

200

OK

401

Unauthorized

403

Forbidden

500

Internal Server Error

Error Codes

See Error Codes.