**To create a transit virtual interface**
The following ``create-transit-virtual-interface`` example creates a transit virtual interface for the specified connection. ::
ws directconnect create-transit-virtual-interface \
--connection-id dxlag-fEXAMPLE \
--new-transit-virtual-interface "virtualInterfaceName=Example Transit Virtual Interface,vlan=126,asn=65110,mtu=1500,authKey=0xzxgA9YoW9h58u8SvEXAMPLE,amazonAddress=192.168.1.1/30,customerAddress=192.168.1.2/30,addressFamily=ipv4,directConnectGatewayId=8384da05-13ce-4a91-aada-5a1baEXAMPLE,tags=[{key=Tag,value=Example}]"
Output::
{
"virtualInterface": {
"ownerAccount": "1111222233333",
"virtualInterfaceId": "dxvif-fEXAMPLE",
"location": "loc1",
"connectionId": "dxlag-fEXAMPLE",
"virtualInterfaceType": "transit",
"virtualInterfaceName": "Example Transit Virtual Interface",
"vlan": 126,
"asn": 65110,
"amazonSideAsn": 4200000000,
"authKey": "0xzxgA9YoW9h58u8SEXAMPLE",
"amazonAddress": "192.168.1.1/30",
"customerAddress": "192.168.1.2/30",
"addressFamily": "ipv4",
"virtualInterfaceState": "pending",
"customerRouterConfig": "\n\n 126\n 192.168.1.2/30\n 192.168.1.1/30\n 65110\n 0xzxgA9YoW9h58u8SvOmXRTw\n 4200000000\n transit\n\n",
"mtu": 1500,
"jumboFrameCapable": true,
"virtualGatewayId": "",
"directConnectGatewayId": "8384da05-13ce-4a91-aada-5a1baEXAMPLE",
"routeFilterPrefixes": [],
"bgpPeers": [
{
"bgpPeerId": "dxpeer-EXAMPLE",
"asn": 65110,
"authKey": "0xzxgA9YoW9h58u8SEXAMPLE",
"addressFamily": "ipv4",
"amazonAddress": "192.168.1.1/30",
"customerAddress": "192.168.1.2/30",
"bgpPeerState": "pending",
"bgpStatus": "down",
"awsDeviceV2": "loc1-26wz6vEXAMPLE"
}
],
"region": "sa-east-1",
"awsDeviceV2": "loc1-26wz6vEXAMPLE",
"tags": [
{
"key": "Tag",
"value": "Example"
}
]
}
}
For more information, see `Creating a Transit Virtual Interface to the Direct Connect Gateway `__ in the *AWS Direct Connect User Guide*.