[cisco-voip] Retrieving device information from CISCO

Andrea Cerioli cerioli at alternet.it
Wed Feb 1 10:00:39 EST 2006


Thanks to Alex for the code.
Unfortunately it is not working for us.
Our Callmanager is 4.1(3).

See below our version of the AXL query and the response.
The error is:
"Operation name in body entry is not consistent with the
  one specified in SOAPAction"

Removing the header "Connection: close" the query lasts forever.


What am I missing?

Query
================================

POST /soap/astsvc.dll HTTP/1.1
Host: 10.89.5.2
User-Agent: Mozilla/4.0
Content-Type: text/xml; charset=utf-8
SOAPAction: "http://schemas.cisco.com/ast/soap/action/#RisPort#SelectCmDevices"
Authorization: Basic =============================
Content-Length: 1514
Expect: 100-continue
Connection: close



<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:tns="http://schemas.cisco.com/ast/soap/"
xmlns:types="http://schemas.cisco.com/ast/soap/encodedTypes"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
     <soap:Header>
          <tns:AstHeader id="id1">
               <SessionId
xsi:type="xsd:string">10.89.5.2-20060201020721</SessionId>
          </tns:AstHeader>
     </soap:Header>
     <soap:Body soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
          <tns:SelectCmDevice>
               <CmSelectionCriteria href="#id1"/>
          </tns:SelectCmDevice>
          <tns:CmSelectionCriteria id="id1" xsi:type="tns:CmSelectionCriteria">
               <MaxReturnedDevices
xsi:type="xsd:unsignedInt">10</MaxReturnedDevices>
               <Class xsi:type="tns:DeviceClass">Phone</Class>
               <Model xsi:type="xsd:unsignedInt">0</Model>
               <Status xsi:type="tns:CmDevRegStat">Any</Status>
               <SelectBy xsi:type="tns:CmSelectBy">Name</SelectBy>
               <SelectItems href="#id2"/>
          </tns:CmSelectionCriteria>
          <soapenc:Array id="id2" soapenc:arrayType="tns:SelectItem[1]">
               <Item href="#id3"/>
          </soapenc:Array>
          <tns:SelectItem id="id3" xsi:type="tns:SelectItem">
               <Item xsi:type="xsd:string">SEP000D29CEC9A0</Item>
          </tns:SelectItem>
     </soap:Body>
</soap:Envelope>



Response:
================================

HTTP/1.1 100 Continue
Server: Microsoft-IIS/5.0
Date: Wed, 01 Feb 2006 14:05:32 GMT

HTTP/1.1 500 ERROR
Server: Microsoft-IIS/5.0
Date: Wed, 01 Feb 2006 14:05:32 GMT
Connection: close
X-Application: XXX
Expires: Sat, 1 Jan 2000 00:00:01 GMT
Cache-Control: No-Cache
Pragma: No-Cache
Connection: Keep-Alive
Content-Type: text/xml; charset="utf-8"
Content-Length: 1002

<?xml version="1.0" encoding="UTF-8" standalone="no"?><SOAP-ENV:Envelope
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"><SOAP-ENV:Body><SOAP-ENV:Fault><faultcode>SOAP-ENV:Client</faultcode><faultstring>Operation
name in body entry is not consistent with the one specified in SOAPAction
header</faultstring><detail><m:ErrorInfo
xmlns:m="http://schemas.cisco.com/ast/soap/"><Version>3.2.0.7</Version><Time>02/01/2006
-
15:05:32</Time><ProcId>2016</ProcId><ThreadId>1928</ThreadId><ArrayOfCallInfo
SOAP-ENC:arrayType='m:CallInfoType[]'><CallInfo><FileName>D:\Builds\ESBUILD_4.1.3.sr.2\ccm_sw\Projects\AST\ISAPI\server\soap\service\astsvc\astsvc.cpp</FileName><LineNo>422</LineNo><ErrorCode>0</ErrorCode><Function>lstrcmp</Function><Params>SelectCmDevice</Params></CallInfo></ArrayOfCallInfo></m:ErrorInfo></detail></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>






More information about the cisco-voip mailing list