How to use vCloud Director API in Zettagrid

The vCloud Director API is a powerful tool for getting information about your vCloud Org VDCs, networking, vApps, VMs and everything else. You can use it for automate all aspects of vCloud Director, such as VM deployment and usage reports.

Zettagrid API endpoint Url

API Reference Guide

vCloud Directory API Reference Guide: https://developer.broadcom.com/xapis/vmware-cloud-director-api/latest/

API Tools

  • vCloud API can be accessed by most of the RESTful API tool such as Postman and scripting tool such as PowerShell and Python.

  • vCloud use with Terraform documentation is also available.

Support

Zettagrid doesn’t provide any technical support of vCloud Director API and the API tools.

Example

Here is an example of how to access Zettagrid Perth Zone vCloud API by using PowerShell.

  • Download this zip file and unzip it to your local machine.

  • Follow the instruction below to use this vCloud API Powershell Module.

#Open a Powershell Window as Administrator. Import the vCloud API module as following Import-Module <Path to vcloud.psm1 file> #Run the following command to login to vCloud by using your Org administrator login details. You will see a `x-vcloud-authorization` token if login successfully. New-vCloudLogin –Username "cloud123456@org_cloud123456" –Password "YOUR_vCLoud_Password" -url "https://mycloud.per.zettagrid.com/api" #Example getting a list of VMs including resources allocation. $VMS = Get-vCloudRequest –EndPoint "query?type=vm" #Export the output to a CSV file. $VMS.QueryResultRecords.VMRecord | ConvertTo-Csv | Out-File C:\Scripts\mj\vcloud.csv

Â