azuregatewayazure-virtual-networkazure-hybrid-connections

Getting BGP peers of an ExpressRoute gateway


I am trying to pull the IP addresses of BGP speakers that establish a peering with an ExpressRoute gateway. For instance, if I create a VirtualNetworkGatewayConnection between my ExpressRoute circuit and an ER gateway, how do I get the IP addresses of the BGP endpoints on the circuit that peer with my gateway?


Solution

  • You could take a look at ExpressRoute REST API and Virtual Network Gateways API

    For example, you could get all peerings information in a specified express route circuit here via clicking the Green Try it on that page. Or try to retrieve a list of routes the virtual network gateway has learned, including routes learned from BGP peers here. It might display the IP address of BGP endpoints in the routing table.