The vSAN Management SDK for .NET provides libraries, sample code, and API reference for developing custom .NET clients against the vSAN Management API. The vSAN Management SDK for .NET depends on the vSphere Web Services SDK of similar level. You use the vSphere Web Services SDK for logging in to vCenter Server and for retrieving vCenter Server managed objects.
API Reference
The vSAN API reference documentation is included in the /docs directory. To view the API Reference, open index.html with a Web browser.
WSDL Files
The vSAN Management SDK for .NET includes vsan.wsdl and vsanService.wsdl in the bindings/wsdl directory. You can use the WSDL definitions to build C# bindings for accessing the vSAN Management API.
Building the vSAN C# DLL
You must have the following components to build the vSAN C# DLL:
- csc.exe - Microsoft® Visual C# Compiler version 4.5 or later.
- sgen.exe - An XML serializer generator tool
- wsdl.exe - Web Service Description Language 4.0 for Microsoft® .NET.
- Microsoft.Web.Services3.dll
- .NET Framework 4.0
- Python 2.7.6
To build the vSAN C# DLL, run the following command:
$ python builder.py vsan_wsdl vsanservice_wsdl
This command generates the following DLL files:
- VsanhealthService.dll
- VsanhealthService.XmlSerializers.dll
Running the Sample Applications
To run the sample applications, run the following command:
.\VsanHealth.exe --username <host or vCenter Server username> --url https://<host or vCenter Server address>/sdk --hostName <host or cluster name> --ignorecert --disablesso
To view information about the parameters, use --help.