<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Question Re: CX_SXML_PARSE_ERROR when consuming web service in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/cx-sxml-parse-error-when-consuming-web-service/qaa-p/735235#M206344</link>
    <description>&lt;P&gt;I solved it myself.&lt;/P&gt;&lt;P&gt;The header has to look like this:&lt;/P&gt;&lt;P&gt;'&amp;lt;soapenv:Header&amp;gt;'&lt;BR /&gt;
 '&amp;lt;wsse:Security soapenv:mustUnderstand="1" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"&amp;gt;'&lt;BR /&gt;
 '&amp;lt;wsse:UsernameToken&amp;gt;'&lt;BR /&gt;
 '&amp;lt;wsse:Username&amp;gt;XXX&amp;lt;/wsse:Username&amp;gt;'&lt;BR /&gt;
 '&amp;lt;wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText"&amp;gt;XXX&amp;lt;/wsse:Password&amp;gt;'&lt;BR /&gt;
 '&amp;lt;/wsse:UsernameToken&amp;gt;'&lt;BR /&gt;
 '&amp;lt;/wsse:Security&amp;gt;'&lt;BR /&gt;
 '&amp;lt;/soapenv:Header&amp;gt;'&lt;/P&gt;</description>
    <pubDate>Wed, 05 Dec 2018 16:41:41 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2018-12-05T16:41:41Z</dc:date>
    <item>
      <title>CX_SXML_PARSE_ERROR when consuming web service</title>
      <link>https://community.sap.com/t5/technology-q-a/cx-sxml-parse-error-when-consuming-web-service/qaq-p/735234</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;
  &lt;P&gt;I have trouble consuming an external webservice.&lt;BR /&gt;I have created the service consumer and the proxy with a wsdl file from the provider of the web service.&lt;BR /&gt;Since there is no header specified in the xml structure by the provider, I have to create it.&lt;BR /&gt;The provider told me to set this as the header for authentification:&lt;/P&gt;
  &lt;P&gt;&amp;lt;wsse:Security soapenv:mustUnderstand="1" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"&amp;gt;&lt;BR /&gt;&amp;lt;wsse:UsernameToken&amp;gt;&lt;BR /&gt;&amp;lt;wsse:Username&amp;gt;Webservice-User&amp;lt;/wsse:Username&amp;gt;&lt;BR /&gt;&amp;lt;wsse:Password &amp;gt;Passwort&amp;lt;/wsse:Password&amp;gt;&lt;BR /&gt;&amp;lt;/wsse:UsernameToken&amp;gt;&lt;BR /&gt;&amp;lt;/wsse:Security&amp;gt;&lt;/P&gt;
  &lt;P&gt;I set the header with method set_request_header of interface if_wsprotocol_ws_header which works fine.&lt;BR /&gt;Now when I call the webservice in my report, I get the following Exception:&lt;/P&gt;
  &lt;P&gt;CX_SXML_PARSE_ERROR - Error while parsing xml-stream: 'undeclared namespace prefix'.&lt;/P&gt;
  &lt;P&gt;There has to be something wrong with the xml but I have no idea if its the header or the body, since the error does not provide any other information.&lt;/P&gt;
  &lt;P&gt;Since the body of the xml was set automatically by the use of a wsdl file, I dont think that the error is in the body.&lt;/P&gt;
  &lt;P&gt;Do you guys have a clue what I could do to find the solution?&lt;/P&gt;
  &lt;P&gt;I can provided the code of my web service call and the xml body, if needed.&lt;/P&gt;
  &lt;P&gt;Thank you very much!&lt;/P&gt;
  &lt;P&gt;Best regards&lt;BR /&gt;Chris&lt;/P&gt;</description>
      <pubDate>Wed, 05 Dec 2018 11:51:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/cx-sxml-parse-error-when-consuming-web-service/qaq-p/735234</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2018-12-05T11:51:20Z</dc:date>
    </item>
    <item>
      <title>Re: CX_SXML_PARSE_ERROR when consuming web service</title>
      <link>https://community.sap.com/t5/technology-q-a/cx-sxml-parse-error-when-consuming-web-service/qaa-p/735235#M206344</link>
      <description>&lt;P&gt;I solved it myself.&lt;/P&gt;&lt;P&gt;The header has to look like this:&lt;/P&gt;&lt;P&gt;'&amp;lt;soapenv:Header&amp;gt;'&lt;BR /&gt;
 '&amp;lt;wsse:Security soapenv:mustUnderstand="1" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"&amp;gt;'&lt;BR /&gt;
 '&amp;lt;wsse:UsernameToken&amp;gt;'&lt;BR /&gt;
 '&amp;lt;wsse:Username&amp;gt;XXX&amp;lt;/wsse:Username&amp;gt;'&lt;BR /&gt;
 '&amp;lt;wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText"&amp;gt;XXX&amp;lt;/wsse:Password&amp;gt;'&lt;BR /&gt;
 '&amp;lt;/wsse:UsernameToken&amp;gt;'&lt;BR /&gt;
 '&amp;lt;/wsse:Security&amp;gt;'&lt;BR /&gt;
 '&amp;lt;/soapenv:Header&amp;gt;'&lt;/P&gt;</description>
      <pubDate>Wed, 05 Dec 2018 16:41:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/cx-sxml-parse-error-when-consuming-web-service/qaa-p/735235#M206344</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2018-12-05T16:41:41Z</dc:date>
    </item>
  </channel>
</rss>

