Query routing entries
Updated at:2025-11-11
Description
Retrieve the routing entries of a specific Cloud Smart Network route table.
Request structure
Plain Text
1GET /v{version}/csn/routeTable/{csnRtId}/rule?marker={marker}&maxKeys={maxKeys} HTTP/1.1
2Host: csn.baidubce.com
3Authorization: authorization string
Request headers
There are no special headers required beyond the common headers.
Request parameters
| Parameter name | Type | Is it required | Parameter position | Description |
|---|---|---|---|---|
| version | String | Yes | URL parameter | API version number, current value is 1. |
| csnRtId | String | Yes | URL parameter | ID of the Cloud Smart Network route table |
| marker | String | No | Query | The starting position of the batch list query is a system-generated string |
| maxKeys | Integer | No | Query | Maximum number of items per page is 1,000, with a default value of 1000. |
Response headers
No additional headers beyond standard ones.
Response parameters
| Parameter name | Type | Description |
|---|---|---|
| csnRtRules | List <[CsnRtRule](CSN/API Reference/Appendix.md#CsnRtRule)> | List of routing entries |
| marker | String | Marker indicating the starting position of the query. If the result list is empty, this field does not exist. |
| isTruncated | Boolean | true indicates there is more data later, false indicates it is the last page |
| nextMarker | String | Obtain the marker value required for retrieving the next page; this field will not appear when isTruncated is false |
| maxKeys | Integer | Maximum number of items included per page |
Request example
Plain Text
1GET /v1/csn/routeTable/csnRt-w3x16fk8nr5kpxkx/rule?marker=csnrr-IyWRnII7&maxKeys=1 HTTP/1.1
2Host: csn.baidubce.com
3Authorization: bce-auth-v1/5e5a8adf11ae475ba95f1bd38228b44f/2016-04-10T08:26:52Z/1800/host;x-bce-date/ec3c0069f9abb1e247773a62707224124b2b31b4c171133677f9042969791f02
Response example
Plain Text
1HTTP/1.1 200 OK
2x-bce-request-id: 1214cca7-4ad5-451d-9215-71cb844c0a50
3Date: Thu, 16 Mar 2017 06:29:48 GMT
4Server: BWS
5{
6 "nextMarker": "csnrr-IyWRn123",
7 "marker": "csnrr-IyWRnII7",
8 "maxKeys": 1,
9 "isTruncated": true,
10 "csnRtRules": [
11 {
12 "ruleId": "cnrr-1db26d78-1781",
13 "routeType": "propagated",
14 "csnId": "csn-m3dwj6tfysnmxmcy",
15 "csnRtId": "csnRt-w3x16fk8nr5kpxkx",
16 "description": null,
17 "fromAttachId": "tgwAttach-wg3z1z5baq3ry1a6",
18 "status": "conflicted",
19 "sourceAddress": null,
20 "destAddress": "192.168.0.0/20",
21 "nextHopId": "vpc-fh43ygs8yp0d",
22 "nextHopName": "Default Virtual Private Cloud",
23 "nextHopRegion": "su",
24 "nextHopType": "vpc",
25 "asPath": "",
26 "community": "",
27 "blackHole": false
28 }
29 ]
30}
