?
Solved

Webservice client calling error

Posted on 2011-10-26
4
Medium Priority
?
1,222 Views
Last Modified: 2012-05-12
I am calling webservice methods by using proxy.
In my proxy class iam using WSE3.0 username tokens to call the soap header.


Iam getting below error:

Encountered error preparing request, no valid response retrieved from server. Exception: EligibilityBase.EligibilityNoResponseException: Encountered error sending or receiving transaction, no valid response retrieved from server. Exception: System.InvalidOperationException: Client found response content type of 'multipart/related; boundary="MIMEBoundaryurn_uuid_A21DAFBFF9538048ED1319647533317"; type="application/xop+xml"; start="<0.urn:uuid:A21DAFBFF9538048ED1319647533318@apache.org>"; start-info="application/soap+xml";action="http://www.caqh.org/SOAP/WSDL/CORETransactions/RealTimeTransactionResponse"', but expected 'application/soap+xml'.
The request failed with the error message:
--
--MIMEBoundaryurn_uuid_A21DAFBFF9538048ED1319647533317
content-type: application/xop+xml; charset=utf-8; type="application/soap+xml"
content-transfer-encoding: binary
content-id: <0.urn:uuid:A21DAFBFF9538048ED1319647533318@apache.org>

Thanks in advance.
0
Comment
Question by:Nettodotnet
  • 2
4 Comments
 
LVL 29

Accepted Solution

by:
Kumaraswamy R earned 2000 total points
ID: 37043655
Hi


which code part get error, provide the ur code

as per my understanding bellow url give some idea

http://stackoverflow.com/questions/2139190/adding-soapheader-username-and-password-with-wse-3-0
0
 

Author Comment

by:Nettodotnet
ID: 37044974
Here is my code:
 COREEnvelopeRealTimeRequest req = new COREEnvelopeRealTimeRequest();
                req.PayloadType = TNCaidSettings.PayloadType;  
                req.ProcessingMode = TNCaidSettings.ProcessingMode;
                req.PayloadID = _transactionNumber.ToString();
                req.TimeStamp = _pickupDate.ToString();
                req.SenderID = TNCaidSettings.SubmitterId;
                req.ReceiverID = TNCaidSettings.ReceiverId.ToString();
                req.CORERuleVersion = TNCaidSettings.CoreRuleVersion;
                req.Payload = _rawTransaction;

                MyCore client = new MyCore();
                try
                {
                   

                    UsernameToken tok = new UsernameToken(TNCaidSettings.UserName, TNCaidSettings.Password, PasswordOption.SendPlainText);
                    client.RequestSoapContext.Security.EncodedMustUnderstand= "false";
                    client.RequestSoapContext.Security.Tokens.Add(tok);
                    client.RequestSoapContext.Addressing.Action = "false";
                    client.Url = TNCaidSettings.RemoteAddress;
                   
                    COREEnvelopeRealTimeResponse resp = client.RealTimeTransaction(req);--Here iam getting above error.
                    return resp.Payload;



Here is the soap message i looked into fiddler:
 
--MIMEBoundaryurn_uuid_A21DAFBFF9538048ED1319721751122

content-type: application/xop+xml; charset=utf-8; type="application/soap+xml"
content-transfer-encoding: binary

content-id: <0.urn:uuid:A21DAFBFF9538048ED1319721751123@apache.org>
<?xml version="1.0" encoding="utf-8"?>
<soapenv:Envelope xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope" xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing">
<soapenv:Header><wsa:To>http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</wsa:To><wsa:MessageID>urn:uuid:A21DAFBFF9538048ED1319721751120</wsa:MessageID><wsa:Action>http://www.caqh.org/SOAP/WSDL/CORETransactions/RealTimeTransactionResponse</wsa:Action><wsa:RelatesTo>urn:uuid:57992efe-9e47-4adb-a79b-322047bdb352</wsa:RelatesTo>
</soapenv:Header>
<soapenv:Body><ns2:COREEnvelopeRealTimeResponse xmlns:ns2="http://www.caqh.org/SOAP/WSDL/CORERule2.0.1.xsd"><PayloadType>X12_10</PayloadType><ProcessingMode>RealTime</ProcessingMode><PayloadID>12319</PayloadID><TimeStamp>2011-10-27T09:22:06-0400</TimeStamp><SenderID>300</SenderID><ReceiverID>13476</ReceiverID><CORERuleVersion>2.0.1</CORERuleVersion><Payload>&lt;![CDATA[--some payload data--
]]&gt;</Payload><ErrorCode>Success</ErrorCode><ErrorMessage>Request was processed successfully</ErrorMessage></ns2:COREEnvelopeRealTimeResponse>
</soapenv:Body>
</soapenv:Envelope>
--MIMEBoundaryurn_uuid_A21DAFBFF9538048ED1319721751122--
                   
0
 

Author Closing Comment

by:Nettodotnet
ID: 37172317
The link is very use full to me
0
 

Expert Comment

by:mbr1022
ID: 37721229
Were you able to resolve this issue?  If so, can you give me some more detail about your solution?  Thanks
0

Featured Post

Granular recovery for Microsoft Exchange

With Veeam Explorer for Microsoft Exchange you can choose the Exchange Servers and restore points you’re interested in, and Veeam Explorer will present the contents of those mailbox stores for browsing, searching and exporting.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

These instructions are based on installing Owncloud on your new raspberry pi connected with a usb HDD. What do you need Part A? A Raspberry Pi, model B. A boot SD card for the Raspberry Pi. A usb HDD An Ethernet cable to connect to the lo…
The task of choosing a web design company to build a website for your business should never be taken in a light manner. Provided the fact that your website will act as a representative to your business and will be responsible for imposing an online …
The purpose of this video is to demonstrate how to set up the WordPress backend so that each page automatically generates a Mailchimp signup form in the sidebar. This will be demonstrated using a Windows 8 PC. Tools Used are Photoshop, Awesome…
Is your OST file inaccessible, Need to transfer OST file from one computer to another? Want to convert OST file to PST? If the answer to any of the above question is yes, then look no further. With the help of Stellar OST to PST Converter, you can e…
Suggested Courses
Course of the Month15 days, 8 hours left to enroll

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question