SOAP Question

C

cormac.foley

Hi,

I wonder could anyone help me out with the following query?

I am trying to access the values in errorCode, errorDescription,
paymentID and redirectURL from the Soap response below.

What java do I use to access these values?

I was trying the following:
------------------------------------------------------
Iterator items =
body.getChildElements(envelope.createName("RequestOneOffConsumerDebitReturnData",
"",
"https://browseandbuy.dialogue.net/jboss-net/services/
MobilePaymentsAPI"));


while (items.hasNext()) {
SOAPBodyElement element = (SOAPBodyElement) items.next();
Iterator scIterator_redirectURL =
element.getChildElements(envelope.createName("redirectURL",
"","https://browseandbuy.dialogue.net/jboss-net/services/
MobilePaymentsAPI"));

etc......but this doesn't work.

----------------------------------------------------

What code could I use to access these values?

Cheers



<?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 soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/
encoding/">

<ns1:requestOneOffConsumerDebitResponse xmlns:ns1="https://
browseandbuy.dialogue.net/jboss-net/services/MobilePaymentsAPI">

<ns1:requestOneOffConsumerDebitResponse href="#id0"/>

</ns1:requestOneOffConsumerDebitResponse>

<multiRef id="id0" soapenc:root="0" soapenv:encodingStyle="http://
schemas.xmlsoap.org/soap/encoding/"
xsi:type="ns2:RequestOneOffConsumerDebitReturnData"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:ns2="http://jboss.uk.dialogue.net:8080/XPAY">
<errorCode xsi:type="xsd:string">00</errorCode>

<errorDescription xsi:type="xsd:string">SUCCESS</errorDescription>

<paymentID xsi:type="xsd:string">D935455A5273E18800E77CBD74DBF45A</
paymentID>

<redirectURL xsi:type="xsd:string">http://wap.vvv.net/?
s=C4766A44352611DCA47F81D36D4DDFEF</redirectURL>

<transactionID xsi:type="xsd:string">D93545585273E18800E77CBD34DC8CA9</
transactionID>

</multiRef>
</soapenv:Body>
</soapenv:Envelope>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,019
Latest member
RoxannaSta

Latest Threads

Top