server-dev

Python wrapper for vCenter Management API 6.5.


Keywords
api, esx, esxi, vmware
License
MIT
Install
pip install server-dev==1.1.1

Documentation

server-dev

Description

This is a Python wrapper for vCenter Management REST API 6.5.

API documentation: https://caidenpyle.com/tutorials/serverdev/main.html

Quick Start

Install the module using PyPI

Windows

python -m pip install server-dev

Linux

pip install server-dev

Pull the module into your namespace:

from serverdev import *

First, you need to authenticate to the vCenter server:

VCenterSession('your vCenter ip', 'your username', 'your password')

Great! Now we can interact with objects on the vCenter server:

host = EsxHost('host ip', 'host username', 'host password')
virtual_machines = host.get_vms()

We can execute functions on esx hosts and virtual machines alike:

host.enter_maint_mode()
for vm in virtual_machines:
    vm.poweroff()