how to manage VMware VM instances through REST API ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2019 05:42 AM
How do we manage (stop/terminate etc.) VMware vm instances through REST APIs ?
In cmdb table "cmdb_ci_vmware_instance" , we try to terminate vm instance by changing vm's state to "terminated". VM instance is not deleted from vCenter. its just change state to "terminated" in form.
response = requests.put(url, auth=(config.snow_username, config.snow_password), headers=headers ,data="{\"state\":\"terminated\"}")
Thanks in advance for your helps/suggestions.
Regards
Soibam

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2019 05:59 AM
All of this is available in VMWare Cloud Management. If you choose to write your own REST APIs, it's going to be time consuming to build and maintain, whereas if you purchase orchestration, you can drop the activities on the workflow and maintain them easier going forward.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-14-2019 12:28 AM
Thanks Chuck Tomasi for reply. Developing own workflow is time consuming.
1. Manually we can terminate/stop VM by just clicking associated UI action "Terminate VM/Stop VM". Is there any way where we can trigger this UI action through business rules/REST API or other means ?
2. VM instance "TEST-OSB" is in power on state and have proper IP address. but same ip address is not reflected in ip address field in table "cmdb_ci_vmware_instance". we are observing this issue in all VMs discovered in SNOW. how do we update ip address in table?