Error Receiving Web Service Response, unexpected response status

Meity Inggrid

New Member
Hi all,

I need your help about connection to webservice.
I want connect with RateGain webservice, here is the code
Code:
DEFINE VARIABLE hWebService AS HANDLE.
DEFINE VARIABLE hPortType      AS HANDLE NO-UNDO.
DEFINE VARIABLE OTA_PingRS     AS LONGCHAR INIT "".
DEFINE VARIABLE OTA_PingRQ     AS LONGCHAR INIT "".
DEFINE VARIABLE rg-con          AS LOGICAL  NO-UNDO INIT NO.

OTA_PingRQ =
'<?xml version="1.0" encoding="utf-8"?>' + '~n'
+ '<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:u="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">' + '~n'
+ '  <s:Header>' + '~n'
+ '    <a:Action s:mustUnderstand="1">http://cgbridge.rategain.com/2011A/ARIService/Ping</a:Action>' + '~n'
+ '    <a:MessageID>urn:uuid:03bb3246-70a5-4997-9e2a-3e73bdb9f9ee</a:MessageID>' + '~n'
+ '    <a:ReplyTo>' + '~n'
+ '      <a:Address>http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address>' + '~n'
+ '    </a:ReplyTo>' + '~n'
+ '    <a:To s:mustUnderstand="1">https://t1.cgbeta.rategain.com/service/rgbr/ari/ari.svc</a:To>' + '~n'
+ '    <o:Security s:mustUnderstand="1" xmlns:o="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">' + '~n'
+ '      <o:UsernameToken u:Id="uuid-1f935b27-461a-4f03-9cc6-6e3fd237aece-1">' + '~n'
+ '        <o:Username>CGBRGAINH</o:Username>' + '~n'
+ '        <o:Password o:Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">br!d@pa7t</o:Password>' + '~n'
+ '      </o:UsernameToken>' + '~n'
+ '    </o:Security>' + '~n'
+ '  </s:Header>' + '~n'
+ '  <s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">' + '~n'
+ '    <OTA_PingRQ Version="0" xmlns="http://www.opentravel.org/OTA/2003/05">' + '~n'
+ '      <EchoData>CGBrige client is calling</EchoData>' + '~n'
+ '    </OTA_PingRQ>' + '~n'
+ '  </s:Body>' + '~n'
+ '</s:Envelope>'.

CREATE SERVER hWebService.
rg-con = hWebService:CONNECT("-WSDL 'https://t1.cgbeta.rategain.com/Service/rgbr/ari/cgbridgeari.wsdl' -nohostverify -Binding 'ARISoap11Binding' -SOAPEndpoint 'https://t1.cgbeta.rategain.com/Service' ").
RUN ARIPort SET hPortType ON hWebService.

RUN OTA_PingRQ IN hPortType
    (INPUT OTA_PingRQ,
    OUTPUT OTA_PingRS).
MESSAGE STRING(OTA_PingRS) VIEW-AS ALERT-BOX INFO.
DELETE OBJECT hWebService.

But when I call "OTA_PingRQ", I got an error message (see error-withOpenEdge.PNG).
I've try to call "OTA_PingRQ" with SOAPUI, and dont get the error messge (see SOAPUI-result.PNG).
Am I made a mistake in the code?
 

Attachments

  • error-withOpenEdge.png
    error-withOpenEdge.png
    46.2 KB · Views: 8
  • SOAPUI-result.png
    SOAPUI-result.png
    77 KB · Views: 7
Top