book
Article ID: 309735
calendar_today
Updated On:
Issue/Introduction
This article provides steps to create a virtual machine through SDK API/method call using vSphere Web Services SDK 5.0.
Environment
VMware vSphere Web Services SDK 5.0
VMware vSphere ESXi 5.0
VMware vSphere Web Services SDK 4.1
Resolution
You can use
CreateVM_Task API/method to create a new virtual machine. You can download vSphere SDK 5.0 at
VMware vSphere Web Services SDK Documentation.
To create a virtual machine through SDK API/method call:
- Log in to the server via the log in API with login credentials. For more information, see VMware vSphere API Reference Documentation Guide.
- Retrieve the Service object.
- Invoke the CreateVM_Task API on the Service object passing the required parameters. Fore more information on CreateVM_Task method, see VMware vSphere API Reference Documentation Guide.
- Refer to the runnable sample code VMCreate.java under the package com.vmware.samples.vm.
For more information, see: