Hello,

I have a simple(maybe?) task to create a script that generates SOAP requests and parses the responses. I managed to create the correct SOAP request and I get the right response. My problem is that i cannot manage to parse the response in a usable way. I tried SOAP::Lite module, but no success..

Here is a sample response that i need to parse:
I need the <Value> and the <CStatus> for each Counter.

<?xml version="1.0" encoding="UTF-8" ?>
- <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <soapenv:Body>
- <ns1:PerfmonCollectSessionDataResponse soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns1="http://schemas.cisco.com/ast/soap/">
- <ArrayOfCounterInfo soapenc:arrayType="ns1:CounterInfoType[12]" xsi:type="soapenc:Array" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(Asterisk-NOC)\CallsActive</Name>
<Value xsi:type="xsd:long">0</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(Asterisk-NOC)\CallsCompleted</Name>
<Value xsi:type="xsd:long">0</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(BTC-DataPhone)\CallsActive</Name>
<Value xsi:type="xsd:long">0</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(BTC-DataPhone)\CallsCompleted</Name>
<Value xsi:type="xsd:long">1</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(BTC-VoIP)\CallsActive</Name>
<Value xsi:type="xsd:long">0</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(BTC-VoIP)\CallsCompleted</Name>
<Value xsi:type="xsd:long">2289</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(ITDNet)\CallsActive</Name>
<Value xsi:type="xsd:long">0</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(ITDNet)\CallsCompleted</Name>
<Value xsi:type="xsd:long">0</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(SpeedyNet_Asterisk)\CallsActive</Name>
<Value xsi:type="xsd:long">1</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(SpeedyNet_Asterisk)\CallsCompleted</Name>
<Value xsi:type="xsd:long">7115</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(Vivatel-VoIP)\CallsActive</Name>
<Value xsi:type="xsd:long">0</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
- <item xsi:type="ns1:CounterInfoType">
<Name xsi:type="ns1:CounterNameType">\\172.30.32.32\Cisco SIP(Vivatel-VoIP)\CallsCompleted</Name>
<Value xsi:type="xsd:long">0</Value>
<CStatus xsi:type="xsd:unsignedInt">0</CStatus>
</item>
</ArrayOfCounterInfo>
</ns1:PerfmonCollectSessionDataResponse>
</soapenv:Body>
</soapenv:Envelope>
Thanks in advance for your help and Best Regards!
Borislav.