4.0

Table Of Contents
VMware, Inc. 11
2
YoucanusetheLab ManagerSOAPAPItodevelopanXMLWebserviceclient.AnXMLWebserviceclientis
anycomponentorapplicationthatreferencesandusesanXMLWebservice.Thisdoesnotrequirea
clientbasedapplication.Inmanycases,XMLWebserviceclientsmightbeotherWeb
applications,suchas
WebFormsorevenotherXMLWebservices.
Thischapterincludesthefollowingtopics:
“RequirementsforDevelopinganApplication”onpage 11
“ObtainingandImportingtheWSDLFile”onpage 11
“SimpleandAdvancedC#CodeSamples”onpage 13
Requirements for Developing an Application
Beforeyoucanstartdevelopinganapplication,reviewtheserequirements:
VMwareassumesthatyouarefamiliarwithbasicprogrammingconceptsandalreadyhavea
programmingdevelopmentenvironmentsetuponyourcomputer.
YoumusthaveaninstanceofLab Managerinstalled,configured,andrunningonyournetwork.
YoumustknowtheaddressoftheLab Managerserverinstance,startingwithitsfullyqualifiedhostname
orIPaddress,forexample,https://hostname.company.com/LabManager.
YoumusthaveanaccountonthetargetLab Managerserver.
Copythecodelistingdisplayedinthenextsection,andpasteitintoyourMicrosoftVisualStudio2005
environment.
Obtaining and Importing the WSDL File
AswithanystandardsbasedSOAPAPIimplementation,theLab ManagerAPIdefinitionisavailableonthe
WebserviceasanXMLformattedWSDLfile.Toobtainthisfile,openInternetExplorer5.5orlaterand
navigatetohttps://<hostname>/LabManager/SOAP/LabManager.asmx?WSDLforyourLab Managerserver.
TheWSDLfiledefinesalltheLab ManagerAPI
callsandobjects.FormoreinformationonWSDL,goto
http://www.w3.org/TR/wsdl.
Importing the WSDL File to Your Development Environment
AfteryouobtaintheWSDLfile,importittoyourdevelopmentenvironmentandgeneratethenecessaryobjects
foruseinbuildingclientWebserviceapplications.Theprocessdependsonyourdevelopmentenvironment,
programminglanguage,andassociatedtools.Forexample,theMicrosoftVisualStudiodevelopment
environmenthandlesthetasksautomatically.Forinstructions
aboutotherdevelopmentplatforms,seethe
productdocumentationforyourplatform.
Getting Started with the Lab Manager
SOAP API
2