<?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>topic Re: Sending a REST POST request from external WebApp to BI Web Services in Developers</title>
    <link>https://communities.sas.com/t5/Developers/Sending-a-REST-POST-request-from-external-WebApp-to-BI-Web/m-p/364442#M5404</link>
    <description>It sounds like something might not be registered in the metadata correctly. Can you take a look at this example and make sure it's set up similarly?&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://support.sas.com/rnd/itech/doc9/dev_guide/websrvcs/sample.html" target="_blank"&gt;http://support.sas.com/rnd/itech/doc9/dev_guide/websrvcs/sample.html&lt;/A&gt;</description>
    <pubDate>Tue, 06 Jun 2017 02:31:45 GMT</pubDate>
    <dc:creator>J_Fredlund</dc:creator>
    <dc:date>2017-06-06T02:31:45Z</dc:date>
    <item>
      <title>Sending a REST POST request from external WebApp to BI Web Services</title>
      <link>https://communities.sas.com/t5/Developers/Sending-a-REST-POST-request-from-external-WebApp-to-BI-Web/m-p/362011#M5403</link>
      <description>&lt;P&gt;I'm developing a Web Application (in ASP.NET Core) that is using SAS Bi Web Services to leverage Stored Processes. I'm having trouble passing data tables between the webapp and SAS.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I managed to load a table from SAS using the HTTP GET request.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now I'm stuck to SENDING data back to SAS. I'm using SOAPui to test the HTTP POST call in order to figure out what is wrong.&lt;/P&gt;&lt;P&gt;first thing first. The Stored Process is very simple. Take the data stream and write it in a SAS library&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;%STPBEGIN(debug=y);  
libname instream XML;

DATA test;
SET instream.product;
run;

%STPEND(debug=y);&lt;/PRE&gt;&lt;P&gt;I set up instream as Data Source XML based data.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I create an XML string from my WebApplication by serializing the model. I have&lt;/P&gt;&lt;PRE&gt;&amp;lt;?xml version="1.0" encoding="utf-16"?&amp;gt;&amp;lt;Value xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"&amp;gt;
&amp;lt;TABLE&amp;gt;
&amp;lt;PRODUCT&amp;gt;&amp;lt;ProductID&amp;gt;1&amp;lt;/ProductID&amp;gt;&amp;lt;Name&amp;gt; palla &amp;lt;/Name&amp;gt;&amp;lt;Description&amp;gt; nike &amp;lt;/Description&amp;gt;&amp;lt;Category&amp;gt; calcio &amp;lt;/Category&amp;gt;&amp;lt;Price&amp;gt;10&amp;lt;/Price&amp;gt;&amp;lt;/PRODUCT&amp;gt;
&amp;lt;PRODUCT&amp;gt;&amp;lt;ProductID&amp;gt;2&amp;lt;/ProductID&amp;gt;&amp;lt;Name&amp;gt; racchetta &amp;lt;/Name&amp;gt;&amp;lt;Description&amp;gt; head &amp;lt;/Description&amp;gt;&amp;lt;Category&amp;gt; tennis &amp;lt;/Category&amp;gt;&amp;lt;Price&amp;gt;100&amp;lt;/Price&amp;gt;&amp;lt;/PRODUCT&amp;gt;
&amp;lt;/TABLE&amp;gt;
&amp;lt;/Value&amp;gt;&lt;/PRE&gt;&lt;P&gt;If I sent the HTTP post request I get the error&lt;/P&gt;&lt;P&gt;"The request sent by the client was syntactically incorrect"&lt;/P&gt;&lt;P&gt;I tryed both content-type text/xml and application/xml (what's the difference by the way?) If i strip the xml properties on top and leave only &amp;lt;Value&amp;gt; i get a&amp;nbsp;WSException: "Expected stream 'instream' was not specified."&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you help me? There is very little documentation about this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 26 May 2017 15:38:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/Sending-a-REST-POST-request-from-external-WebApp-to-BI-Web/m-p/362011#M5403</guid>
      <dc:creator>Crysis85</dc:creator>
      <dc:date>2017-05-26T15:38:05Z</dc:date>
    </item>
    <item>
      <title>Re: Sending a REST POST request from external WebApp to BI Web Services</title>
      <link>https://communities.sas.com/t5/Developers/Sending-a-REST-POST-request-from-external-WebApp-to-BI-Web/m-p/364442#M5404</link>
      <description>It sounds like something might not be registered in the metadata correctly. Can you take a look at this example and make sure it's set up similarly?&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://support.sas.com/rnd/itech/doc9/dev_guide/websrvcs/sample.html" target="_blank"&gt;http://support.sas.com/rnd/itech/doc9/dev_guide/websrvcs/sample.html&lt;/A&gt;</description>
      <pubDate>Tue, 06 Jun 2017 02:31:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/Sending-a-REST-POST-request-from-external-WebApp-to-BI-Web/m-p/364442#M5404</guid>
      <dc:creator>J_Fredlund</dc:creator>
      <dc:date>2017-06-06T02:31:45Z</dc:date>
    </item>
  </channel>
</rss>

