Skip to content

Instantly share code, notes, and snippets.

@jsidhu
Created June 29, 2016 17:03
Show Gist options
  • Save jsidhu/0098de77c12a2a5fcdbaf8c8352359a0 to your computer and use it in GitHub Desktop.
Save jsidhu/0098de77c12a2a5fcdbaf8c8352359a0 to your computer and use it in GitHub Desktop.
vnc api example - list virtual machines
from vnc_api import vnc_api
myVnc = vnc_api.VncApi(api_server_host='127.0.0.1')
vms = myVnc.virtual_machines_list(detail=True, fields=['virtual_machine_interface_back_refs', 'virtual_router_back_ref'])
# See whats in the first object in the list
vms[0].__dict__
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment