本接口用于获取一个路由表中的路由条目的列表。
下表列出了接口特定的请求参数以及公共请求参数 Action 和 Version。 其他公共参数,请参见公共参数。
参数 | 类型 | 是否必选 | 示例值 | 描述 |
|---|---|---|---|---|
Action | String | 是 | ListRouteEntries | 接口名称。当前 API 的名称为 ListRouteEntries。 |
Version | String | 是 | 2021-04-30 | 接口版本。当前 API 的版本为 2021-04-30。 |
route_table_identity | String | 是 | route-table-7fs74n**** | 路由表 ID。您可以通过 ListRouteTables 接口获取路由表 ID。 |
route_entry_type_list | String[] | 是 | custom | 路由条目类型。取值范围:
|
route_entry_next_hop_list | String[] | 否 | 172.**.**.3,172.**.**.2 | 路由条目的下一跳列表。下一跳之间用半角逗号(,)分隔。 如果不指定该参数,系统将查询所有相关的路由条目。 |
page | Integer | 否 | 1 | 路由条目列表的页码。 默认值:1。 |
limit | Integer | 否 | 10 | 分页查询时设置的每页行数。 默认值:1000。 |
order_by | Integer | 否 | 1 | 查询出来的路由条目的排列顺序,按照创建时间排序。取值范围:
|
下表仅列出本接口特有的返回参数。更多信息请参见返回结果。
参数 | 类型 | 示例值 | 描述 |
|---|---|---|---|
route_entry_instances | Object[] | - | 路由条目列表。 |
count | Integer | 1 | 路由条目个数。 |
GET https://veenedge.volcengineapi.com/?Action=ListRouteEntries&Version=2021-04-30 &route_table_identity=route-table-29gwx9**** &route_entry_type_list=system &<其他公共参数>
{ "ResponseMetadata": { "RequestId": "202404011939273FD0650EACDF5D8B****", "Action": "ListRouteEntries", "Version": "2021-04-30", "Service": "veenedge", "Region": "cn-north-1" }, "Result": { "route_entry_instances": [ { "account_identity": 210006****, "user_identity": 0, "route_identity": "", "type": "system", "dest_cidr": "10.**.**.0/24", "next_hop_type": "LOCAL", "next_hop": "LOCAL", "desc": "VPC子网系统路由", "is_enable": true, "next_hop_instance_id": "", "route_table_identity": "route-table-wrqtcg****", "create_time": 1711971568, "update_time": 1711971568 }, { "account_identity": 210006****, "user_identity": 0, "route_identity": "", "type": "system", "dest_cidr": "10.**.**.0/24", "next_hop_type": "LOCAL", "next_hop": "LOCAL", "desc": "VPC子网系统路由", "is_enable": true, "next_hop_instance_id": "", "route_table_identity": "route-table-wrqtcg****", "create_time": 1711971568, "update_time": 1711971568 } ], "count": 2 } }
如果响应正文中包含 Error 字段,则表示 API 请求失败。关于错误码的更多信息,参见错误码。