web_service_call soap error when using SOAPHeader with wsa: SOAP header Action was not understood

Issue with web_service_call when using SOAPHeader with addressing (wsa) namespace elements: Soap error: Message:SOAP header Action was not understood.


The web_service_call in my script has a custom header that looks like this (URL has been modified to mask the actual host/service names):


"SOAPHeader=<SoapHeader xmlns:wsa=\"http://www.w3.org/2005/08/addressing\" xmlns:soap=\"http://www.w3.org/2003/05/soap-envelope\">"
            "<wsa:Action soap:mustUnderstand=\"1\">http://host.com/serviceurl/action</wsa:Action>"
            "<wsa:To soap:mustUnderstand=\"1\">">perfepkbsvcs/.../SoapHeader>",



The service call requres the explicit To and Action elements in the header and it works when used with soapui and other utilities.


It works here as well, that is LR is able to replay the step and fetch the correct soap response from the server.

However, I see this error in the extended replay log and the output arguments were not saved to the parameters.


Action.c(3): Error Exceptions:
Action.c(3): System.Exception: Soap error:
Message:SOAP header Action was not understood.
at Mercury.LR.LrWsNetClient.ProxyCreator.InvokeMethod(String sMethod, IWSMethodParameters mParams, String sAsyncEvent)
at Mercury.LR.LrWsNetClient.NetReplay.InvokeMethod(String sMethod, IWSMethodParameters mParams, String sAsyncEvent)
Action.c(3): <CENTER><STRONG><FONT COLOR=#FF0031>Failed to retrieve output arguments/checkpoints - SOAP fault occurred</FONT></STRONG></CENTER>


Is the soapheader format correct for how to specify the wsa and soap namespace when we need to explicitly call the Action and To attributes in the header?




  • Instead of using Web_service_call and importing from WSDL , did you try using raw soap_request with web_add_header


    Generally to make any changes you need to use UI instead of changing direct code. Try creating test case again and just use UI to get the results, don't do any changes to code and see it works.




  • I have a similar issue where in my SOAP request is failing

    I keep getting errors as SoapHeader and ws un recogonized


            "<wsa:Action xmlns:wsa=\"http://schemas.xmlsoap.org/ws/2004/08/addressing\">http://www.host.com/Webservices/TranscriptAndTask/GetTranscriptAndTasks</wsa:Action>"
            "</wsa:ReplyTo><wsa:To>https://host/Service.asmx</wsa:To><wsse:Security soap:mustUnderstand=\"1\">"
            "xml:request=<request><Request corpName=\"loadtest2014\"><User id=\""
            "d2Hnd5Dgvg\"><RequestTypes><Inbox /><Transcript inprogressOnly=\""
            "false\" pageNumber=\"1\" /><Task pendingTasksOnly=\"false\" /></"