Get List of vCloud External Networks

To view the list of external networks, use the following request:

GET /settings/external_networks.xml
GET /settings/external_networks.json

XML Request Example 

curl -i -X GET -u 'user:userpass' --url http://onapp.test/settings/external_networks.xml -H 'Accept: application/xml' -H 'Content-type: application/xml'

JSON Request Example 

curl -i -X GET -u 'user:userpass' --url http://onapp.test/settings/external_networks.json -H 'Accept: application/json' -H 'Content-type: application/json'

XML Output Example 

 <external_networks type="array">
  <external_network>
    <created_at type="datetime">2016-02-13T10:31:06+02:00</created_at>
    <default_nat_rule_number type="integer">9999</default_nat_rule_number>
    <default_outside_ip_address_id nil="true"/>
    <dns_suffix nil="true"/>
    <dvportgroup>dvportgroup-33</dvportgroup>
    <enabled type="boolean">false</enabled>
    <fence_mode nil="true"/>
    <gateway>172.16.0.254</gateway>
    <id type="integer">1</id>
    <identifier>32eef56a-799b-4a2e-a3c3-b663c24c43c5</identifier>
    <ip_address_pool_id nil="true"/>
    <is_nated type="boolean">true</is_nated>
    <label>External Net</label>
    <netmask>255.255.255.0</netmask>
    <network_group_id type="integer">12</network_group_id>
    <prefix_size nil="true"/>
    <primary_dns nil="true"/>
    <secondary_dns nil="true"/>
    <shared type="boolean">false</shared>
    <updated_at type="datetime">2016-02-13T10:31:06+02:00</updated_at>
    <user_id nil="true"/>
    <vapp_id nil="true"/>
    <vdc_id nil="true"/>
    <vlan nil="true"/>
  </external_network>
  ...
</external_networks>

Where:

created_at -  the date in the [YYYY][MM][DD]T[hh][mm][ss]Z format 

default_nat_rule_number - default NAT rule

default_outside_ip_address_id - ID of the outside IP address

dns_suffix - the DNS suffix

dvportgroup - the portgroup that backs this network

enabled - whether the network is enabled or not

fence_mode - isolation type of the network

gateway - the gateway associated with the network

id - the ID of the network

identifier - the identifier of the network

ip_address_pool_id -  ID of the IP Address Pool

is_nated - set true to use NAT for translating the traffic. Set false if you are using your own firewall with external IP address 

label - the name of the network

netmask - IP of the network mask

network_group_id - network zone ID

prefix_size - subnet prefix size

primary_dns -IP address of the primary domain name system (DNS) server

secondary_dns - IP address of the secondary domain name system (DNS) server

shared - whether this external network is shared or not

updated_at -  the date in the [YYYY][MM][DD]T[hh][mm][ss]Z format 

user_id - owner ID

vapp_id - the vApp associated with the network

vdc_id - the resource pool associated with the network

vlan - VLAN number