QUESTION
How to navigate the Traverse WSDL pages?
RESOLUTION
In general, to find the descriptions of the various parameters for a service method:
- Navigate to https://traverse_server/api
- Find the correct section heading for the object of interest (e.g. device)
- Select the 'WSDL' link (e.g. https://traverse_server/api/soap/device?wsdl
- Find the 'location=' line near the top, then navigate to the specified URL (e.g. https://traverse_server/api/soap/device?wsdl=DeviceService.wsdl)
For example; on the 'device service' WSDL page the 'searchCriteria' element is defined as containing 'searchOption' and 'searchTerm' elements. 'From this WSDL page 'searchOption' is defined as:
<xs:simpleType name="searchOption">
<xs:restriction base="xs:string">
<xs:enumeration value="DEPARTMENT_SERIAL_NUMBER"/>
<xs:enumeration value="DEVICE_SERIAL_NUMBER"/>
<xs:enumeration value="DEVICE_NAME"/>
<xs:enumeration value="DEVICE_ADDRESS"/>
<xs:enumeration value="DEVICE_TYPE"/>
<xs:enumeration value="DEVICE_MODEL"/>
<xs:enumeration value="DEVICE_STATUS"/>
<xs:enumeration value="VENDOR_NAME"/>
<xs:enumeration value="TAG_1"/>
<xs:enumeration value="TAG_2"/>
<xs:enumeration value="TAG_3"/>
<xs:enumeration value="TAG_4"/>
<xs:enumeration value="TAG_5"/>
<xs:enumeration value="TEST_SERIAL_NUMBER"/>
<xs:enumeration value="TEST_NAME"/>
<xs:enumeration value="TEST_STATUS"/>
<xs:enumeration value="TEST_TYPE"/>
<xs:enumeration value="TEST_SUB_TYPE"/>
<xs:enumeration value="ELEMENT_NAME"/>
<xs:enumeration value="ELEMENT_CATEGORY"/>
<xs:enumeration value="CONTAINER_NAME"/>
<xs:enumeration value="CONTAINER_SERIAL_NUMBER"/>
<xs:enumeration value="PARENT_CONTAINER_SERIAL_NUMBER"/>
<xs:enumeration value="CONTAINER_STATUS"/>
<xs:enumeration value="VM_STATUS"/>
<xs:enumeration value="MAP_NAME"/>
<xs:enumeration value="FREEFORM"/>
</xs:restriction>
</xs:simpleType>
One way to list all devices in a certain department could be to search by department serial number:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:dev="http://traverse.zyrion.com/05/06/device">
<soapenv:Header/>
<soapenv:Body>
<dev:getStatuses>
<deviceStatusesRequest>
<password>traverse</password>
<username>superuser</username>
<searchCriterias>
<searchOption>DEPARTMENT_SERIAL_NUMBER</searchOption>
<searchTerms>49</searchTerms>
</searchCriterias>
</deviceStatusesRequest>
</dev:getStatuses>
</soapenv:Body>
</soapenv:Envelope>
To find all devices that begin with the letters 'VCA' in their names, the 'Freeform' search option may be used;
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:dev="http://traverse.zyrion.com/05/06/device">
<soapenv:Header/>
<soapenv:Body>
<dev:getStatuses>
<deviceStatusesRequest>
<password>traverse</password>
<username>superuser</username>
<searchCriterias>
<searchOption>FREEFORM</searchOption>
<searchTerms>device:^vca</searchTerms>
</searchCriterias>
</deviceStatusesRequest>
</dev:getStatuses>
</soapenv:Body>
</soapenv:Envelope>
Note that the value of 'searchTerms' is a regular expression to match the beginning of the device name. A search term of 'device:vca' will match all devices with 'vca' in their names.
For other examples of 'Freeform' search terms, navigate to the Event Manager view (Status->Events) in the Traverse user interface, then click on the 'help' icon next to the Search field (i.e. a blue circle with a question mark).
APPLIES TO
All versions of Traverse
REFERENCE
None