Help Center/ Enterprise Switch/ API Reference/ Enterprise Switch/ Querying Enterprise Switch Specifications
Updated on 2025-12-04 GMT+08:00

Querying Enterprise Switch Specifications

Function

This API is used to query the enterprise switch specifications available to a tenant.

Authorization Information

Each account has all the permissions required to call all APIs, but IAM users must be assigned the following required identity policy-based permissions. For details about the required permissions, see Permissions Policies and Supported Actions.

Action

Access Level

Resource Type (*: required)

Condition Key

Alias

Dependencies

esw:flavor:list

List

-

-

-

-

URI

GET /v3/{project_id}/l2cg/flavors

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

  • Definition: ID of the project to which the enterprise switch belongs.

  • Constraints: N/A

  • Range: N/A

  • Default value: N/A

Request Parameters

None

Response Parameters

Status code: 200

Table 2 Response body parameters

Parameter

Type

Description

flavors

Array of Flavor objects

  • Definition: Response body for querying the instance flavors.

  • Constraints: N/A

  • Range: N/A

  • Default value: N/A

request_id

String

  • Definition: Unique request ID.

  • Constraints: The value is in the UUID format.

  • Range: N/A

  • Default value: N/A

Table 3 Flavor

Parameter

Type

Description

name

String

  • Definition: Enterprise switch flavor name.

  • Constraints: N/A

  • Range:

    • l2cg.small.ha

    • l2cg.medium.ha

    • l2cg.large.ha

  • Default value: N/A

id

String

  • Definition: Enterprise switch flavor ID.

  • Constraints: N/A

  • Range: 1 to 3.

  • Default value: N/A

connections

Integer

  • Definition: Maximum number of Layer 2 connections that an enterprise switch with this flavor supports.

  • Constraints: N/A

  • Range: 1, 3, or 6

  • Default value: N/A

bandwidth

Integer

  • Definition: Maximum bandwidth that an enterprise switch with this flavor supports.

  • Constraints: The unit is Gbit/s.

  • Range: 3, 5, or 10

  • Default value: N/A

pps

Integer

  • Definition: Maximum number of packets that an enterprise switch with this flavor supports.

  • Constraints: N/A

  • Range: 500000, 1000000, or 2000000

  • Default value: N/A

available_zones

Array of strings

  • Definition: List of AZs where instances with this flavor are available.

  • Constraints: N/A

  • Range: N/A

  • Default value: N/A

Example Requests

GET https://{{endpoint}}/v3/060576782980d5762f9ec014dd2f1148/l2cg/flavors

Example Responses

Status code: 200

The GET operation is successful. For more status codes, see Status Codes.

{
  "flavors" : [ {
    "name" : "l2cg.small.ha",
    "id" : "1",
    "connections" : 1,
    "bandwidth" : 3,
    "pps" : 500000,
    "available_zones" : [ "cn-southwest-242b", "cn-southwest-242a" ]
  }, {
    "name" : "l2cg.medium.ha",
    "id" : "2",
    "connections" : 3,
    "bandwidth" : 5,
    "pps" : 1000000,
    "available_zones" : [ "cn-southwest-242b", "cn-southwest-242a" ]
  }, {
    "name" : "l2cg.large.ha",
    "id" : "3",
    "connections" : 6,
    "bandwidth" : 10,
    "pps" : 2000000,
    "available_zones" : [ "cn-southwest-242b", "cn-southwest-242a" ]
  } ],
  "request_id" : "7c7d90893b78412b49b2075a685fdebd"
}

Status Codes

Status Code

Description

200

The GET operation is successful. For more status codes, see Status Codes.

Error Codes

See Error Codes.