ASP.NET SOAP Client with non-WSDL Endpoint - works using SOAPUI client RRS feed

  • Question

  • I am trying to create a SOAP client in ASP.NET, framework 3.5, using Basic Authentication and WS Security All of the examples I have seen use a WSDL endpoint - unfortunately the way that the Web service is designed, one invoked a web method directly - WSDL is not available - so I cannot use 'add a service reference'

    Endpoint is something like: https://webservice.com/GetFirstName I have a username and password.

    USING SMARTBEAR SOAP UI client (great tool!), I got this to work by creating an XML request like:

    <'element'> '<'UserID'>'frank1<''<'UserID'> <'element'>

    Then I enter the Endpoint URL, credentials.

    When I execute, I hit the endpoint with username/password, authenticates, and I get an XML response like:

    <'data contentType="application/xml; charset=UTF-8" contentLength="515"> '' <'element'> <'FirstName'>Frank<'/FirstName> <'/element'>

    So the above is working in SOAP UI Client.

    So now how do I go about transitioning this to work in an ASP.NET application? I have some experience with WCF, but again most examples I have seen expect a WSDL which I don't have.

    How can I create a SOAP object envelope, using Basic authentication, populate the SOAP header with credentials, populate the body with the example XMl above, and then target the URL endpoint to get this to work? (Hope I have worded this correctly)

    Tuesday, January 12, 2016 10:42 PM


  • They'll help you over here.





    Regards, Dave Patrick ....
    Microsoft Certified Professional
    Microsoft MVP [Windows]

    Disclaimer: This posting is provided "AS IS" with no warranties or guarantees , and confers no rights.

    • Proposed as answer by Mike Laughlin Wednesday, January 13, 2016 5:02 PM
    • Marked as answer by Dave PatrickMVP Saturday, January 23, 2016 6:04 PM
    Tuesday, January 12, 2016 10:48 PM