Queries the route association relationships created for an Enterprise Edition transit router route table or a network instance connection.
Operation description
When you call the ListTransitRouterRouteTableAssociations operation, specify at least one of the request parameters TransitRouterRouteTableId and TransitRouterAttachmentId:
If you specify only the TransitRouterRouteTableId parameter, the system queries the network instance connections that have route association relationships with the specified Enterprise Edition transit router route table.
If you specify only the TransitRouterAttachmentId parameter, the system queries the Enterprise Edition transit router route tables that have route association relationships with the specified network instance connection.
- If you specify both the TransitRouterRouteTableId and TransitRouterAttachmentId parameters, the system queries the route association relationship between the specified network instance connection and the specified Enterprise Edition transit router route table.
If a route association relationship exists between the network instance connection and the Enterprise Edition transit router route table, the system returns the information about the route association relationship.
If no route association relationship exists between the network instance connection and the Enterprise Edition transit router route table, the TransitRouterAssociations array is empty.
When you call the ListTransitRouterRouteTableAssociations operation, make sure that the parameter values you specify are correct. If you specify incorrect parameter values, the system still returns a RequestId but does not return the route association relationships created for the Enterprise Edition transit router route table or network instance connection.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
cen:ListTransitRouterRouteTableAssociations |
get |
TransitRouterPeerAttachment
TransitRouterRouteTable
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| MaxResults |
integer |
No |
The number of entries per page for a paged query. Default value: 50. |
50 |
| NextToken |
string |
No |
The pagination token that is used in the next request to retrieve a new page of results. Valid values:
|
a415**** |
| TransitRouterRouteTableId |
string |
No |
The ID of the Enterprise Edition transit router route table. |
vtb-bp1dudbh2d5na6b50**** |
| TransitRouterAttachmentId |
string |
No |
The ID of the network instance connection. |
tr-attach-nls9fzkfat8934**** |
| TransitRouterAttachmentResourceId |
string |
No |
The ID of the next hop resource. |
vpc-bp1h8vbrbcgohcju5**** |
| TransitRouterAttachmentResourceType |
string |
No |
The type of the next hop resource. Valid values:
|
VPC |
| Status |
string |
No |
The status of the route association. Valid values:
|
Active |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response parameters. |
||
| NextToken |
string |
The pagination token that is used in the next request to retrieve a new page of results. Valid values:
|
a415**** |
| RequestId |
string |
The request ID. |
F6B1D9AB-176D-4399-801D-8BC576F4EB0D |
| TotalCount |
integer |
The total number of entries returned. |
1 |
| MaxResults |
integer |
The number of entries per page for a paged query. |
50 |
| TransitRouterAssociations |
array<object> |
The list of route association relationships. |
|
|
object |
The information about a route association relationship. |
||
| TransitRouterAttachmentId |
string |
The ID of the network instance connection. |
tr-attach-nls9fzkfat8934**** |
| Status |
string |
The status of the route association. Valid values:
|
Associating |
| ResourceType |
string |
The type of the next hop resource. Valid values:
|
VPC |
| ResourceId |
string |
The ID of the next hop resource. |
vpc-bp1h8vbrbcgohcju5**** |
| TransitRouterRouteTableId |
string |
The ID of the Enterprise Edition transit router route table. |
vtb-bp1dudbh2d5na6b50**** |
Examples
Success response
JSON format
{
"NextToken": "a415****",
"RequestId": "F6B1D9AB-176D-4399-801D-8BC576F4EB0D",
"TotalCount": 1,
"MaxResults": 50,
"TransitRouterAssociations": [
{
"TransitRouterAttachmentId": "tr-attach-nls9fzkfat8934****",
"Status": "Associating",
"ResourceType": "VPC",
"ResourceId": "vpc-bp1h8vbrbcgohcju5****",
"TransitRouterRouteTableId": "vtb-bp1dudbh2d5na6b50****"
}
]
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | IllegalParam.NextToken | The parameter NextToken is invalid. | The error message returned because the NextToken parameter is set to an invalid value. Check the value and try again. |
| 400 | IllegalParam.MaxResults | The specified MaxResults is illegal. | MaxResults illegal. |
| 400 | InvalidParameter | Invalid parameter. | The error message returned because the parameter is set to an invalid value. |
| 400 | Unauthorized | The AccessKeyId is unauthorized. | The error message returned because you do not have the permissions to perform this operation. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.