To add a network to an organization VDC, an administrator POSTs an OrgVdcNetwork element to the VDC's add URL for networks. An organization VDC network with a direct connection to an external network must be created by a system administrator. All other organization VDC network types can be created by either a system administrator or an organization administrator.

The contents of the Configuration element of the OrgVdcNetwork define the properties of the network, including its connections to other networks.

For more information about the types of networks you can create and the resources on which they depend, see About VMware Cloud Director Networks.

Prerequisites

This operation requires the rights included in the predefined Organization Administrator role or an equivalent set of rights. Verify that you are logged in to the vCloud Air Compute Service as an Account Administrator.

Procedure

  1. Retrieve the XML representation of the organization VDC to which you want to add the network.
    This request retrieves the admin view of an organization VDC.
    GET https://vcloud.example.com/api/admin/vdc/44
  2. Examine the response to locate the Link element that contains the URL for adding networks to the VDC.
    This element has a rel attribute value of add and a type attribute value of application/vnd.vmware.admin.orgVdcNetwork+xml, as shown here:
    <Link
       rel="add"
       type="application/vnd.vmware.admin.orgVdcNetwork+xml"
       href="https://vcloud.example.com/api/admin/vdc/44/networks" />
  3. Create an OrgVdcNetwork element.
  4. POST the OrgVdcNetwork element to the URL described in Step 2.

Results

The server takes the requested action and returns a Task element that tracks the progress of the request. The Owner element of this task includes the href attribute of the new network. When the task completes, you can use the value of this attribute with a GET request to retrieve the XML representation of the new network.