Queries the elastic network interfaces (ENIs) within a virtual private cloud (VPC) that can serve as multicast sources or multicast members for multicast communication.
Operation description
Before you invoke the ListGrantVSwitchEnis operation, make sure that the VPC-connected instance is connected to Cloud Enterprise Network (CEN). For more information, see CreateTransitRouterVpcAttachment.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
cen:ListGrantVSwitchEnis |
get |
*CenInstance
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| CenId |
string |
Yes |
The ID of the CEN instance to which the VPC-connected instance is connected. |
cen-a7syd349kne38g**** |
| VpcId |
string |
Yes |
The ID of the VPC-connected instance. |
vpc-p0w9alkte4w2htrqe**** |
| VSwitchId |
string |
Yes |
The ID of a vSwitch in the VPC-connected instance. You can query network interface controller (NIC) information for only one vSwitch at a time. |
vsw-p0w9s2ig1jnwgrbzl**** |
| NextToken |
string |
No |
The token for the next query. Valid values:
|
AAAAAdDWBF2**** |
| MaxResults |
integer |
No |
The maximum number of entries per page for a paged query. Valid values: 10 to 500. Default value:
|
20 |
| NetworkInterfaceId |
array |
No |
The IDs of network interface controllers (NICs). |
|
|
string |
No |
The ID of the elastic network interfaces (ENIs). Currently, only ENIs associated with ECS instances can serve as multicast sources. The system sends multicast traffic to the multicast group from the primary private IP address of the elastic network interfaces (ENIs). |
eni-wz9a2sgsskvw69v2**** |
|
| NetworkInterfaceName |
string |
No |
The name of the elastic network interfaces (ENIs). You can use this parameter to filter network interface controllers (NICs) by name. |
test-eni-name |
| PrimaryIpAddress |
string |
No |
The primary private IP IPv4 address of the elastic network interfaces (ENIs). You can use this parameter to filter network interface controllers (NICs) by primary private IP address. |
192.168.**.** |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response parameters. |
||
| RequestId |
string |
The request ID. |
DBFE1736-2F33-5309-9954-875B11E9519D |
| TotalCount |
string |
The total number of entries returned. Important When you use the MaxResults and NextToken parameters for paging, the returned Total parameter value is meaningless. |
6 |
| GrantVSwitchEnis |
array<object> |
The list of network interface controller (NIC) information. |
|
|
object |
The elastic network interfaces (ENIs) information. Each entry contains the details of a network interface controller (NIC). |
||
| VpcId |
string |
The VPC-connected instance ID. |
vpc-p0w9alkte4w2htrqe**** |
| VSwitchId |
string |
The vSwitch ID. |
vsw-p0w9s2ig1jnwgrbzl**** |
| NetworkInterfaceId |
string |
The ID of the elastic network interfaces (ENIs). This is the network interface controller (NIC) identifier. |
eni-p0w172vv82kxzb49**** |
| Description |
string |
The description of the elastic network interfaces (ENIs). This describes the network interface controller (NIC). |
created by CBN |
| TransitRouterFlag |
boolean |
Indicates whether the elastic network interface (ENI) is created by a transit router for routing and forwarding purposes.
Elastic network interfaces (ENIs) created by transit routers cannot serve as multicast sources or multicast members. |
false |
| NetworkInterfaceName |
string |
The name of the elastic network interfaces (ENIs). This is the network interface controller (NIC) name. |
my-eni-name |
| PrimaryIpAddress |
string |
The primary private IP IPv4 address of the elastic network interfaces (ENIs). This is the network interface controller (NIC) primary private IP address. |
192.168.**.** |
| NextToken |
string |
The token returned for this query. |
AAAAAdDWBF2**** |
| MaxResults |
integer |
The maximum number of entries returned for this query. |
20 |
Examples
Success response
JSON format
{
"RequestId": "DBFE1736-2F33-5309-9954-875B11E9519D",
"TotalCount": "6",
"GrantVSwitchEnis": [
{
"VpcId": "vpc-p0w9alkte4w2htrqe****",
"VSwitchId": "vsw-p0w9s2ig1jnwgrbzl****",
"NetworkInterfaceId": "eni-p0w172vv82kxzb49****",
"Description": "created by CBN",
"TransitRouterFlag": false,
"NetworkInterfaceName": "my-eni-name",
"PrimaryIpAddress": "192.168.**.**"
}
],
"NextToken": "AAAAAdDWBF2****",
"MaxResults": 20
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidCenId.NotFound | The specified CenId is not found. | The error message returned because the specified CEN instance ID does not exist. |
| 400 | InvalidVpcId.NotFound | The specified VpcId is not found. | The error message returned because the specified VPC ID (VpcId) is invalid. |
| 400 | InvalidOperation.MulticastDomainAssociationNotExist | Operation is invalid because multicast association domain association not exist. | The error message returned because this operation is not supported when the specified multicast domain is not associated with the specified resource. |
| 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.