In addition to this programmer's guide and the schema reference, VMware provides code samples written in Java that client application developers can use as a model for the common workflows in the automation of cloud interactions.

At a high-level, the code samples provide workflows to write a client that programmatically logs in to vCloud Air and establishes a session with vCloud to manage compute services and virtual resources. VMware provides code samples for three sample client applications:

Queries all existing virtual data centers across all regions in both a customer's Dedicated Cloud and Virtual Private Cloud. To run this code sample, you must log in as a user assigned to one or more of the following roles: Virtual infrastructure administrator, Read-Only administrator, or End User.

Creates a virtual machine by using a template, powers on the virtual machine, and obtain its IP address for subsequent connections. Then, runs a Web service on that virtual machine. To run this code sample, you must log in as a user assigned to one or more of the following roles: Virtual infrastructure administrator or End User.

Adds a NAT rule to enable external HTTPS requests to a Web service running on a virtual machine in the virtual data center and adds a firewall rule to prevent all other access. To run this code sample, you must log in as a user assigned to the Virtual infrastructure administrator role.

The code samples support the standard use case wherein a company purchases by logging in to My VMware both Virtual Private Cloud and Dedicated Cloud capacity in different regions of vCloud Air. A vCloud Air Account Administrator logs in to the vCloud Air Web UI to create a user and assign that user to an appropriate access role.

Additionally, the code samples illustrate how to establish a vCloud session, request the vCloud instance version, and set the correct version header.

The code samples are available for download from the VMware Community > VMware Technology Network (VMTN) Forums > VMware Developer > Sample Code at https://communities.vmware.com/community/vmtn/developer/codecentral.