<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://community.appian.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>KB-1975 Web API calls return unexpected results after enabling SAML authentication</title><link>https://community.appian.com/support/w/kb/1502/kb-1975-web-api-calls-return-unexpected-results-after-enabling-saml-authentication</link><description /><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>KB-1975 Web API calls return unexpected results after enabling SAML authentication</title><link>https://community.appian.com/support/w/kb/1502/kb-1975-web-api-calls-return-unexpected-results-after-enabling-saml-authentication</link><pubDate>Tue, 06 Aug 2019 14:31:55 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:c7afb0bb-8831-4bb8-a11c-ebc4007e5b18</guid><dc:creator>Rebecca Jonas</dc:creator><comments>https://community.appian.com/support/w/kb/1502/kb-1975-web-api-calls-return-unexpected-results-after-enabling-saml-authentication#comments</comments><description>Current Revision posted to Appian Knowledge Base by Rebecca Jonas on 8/6/2019 2:31:55 PM&lt;br /&gt;
&lt;h2&gt;Symptoms&lt;/h2&gt;
&lt;p&gt;After enabling SAML authentication for Appian, Web API calls return a &lt;code&gt;200 OK&lt;/code&gt; response code with an unexpected HTML response body that fails to parse in the external system calling the Web API. For example,&amp;nbsp;the error observed in the Web API client may indicate that the response was invalid JSON or that a particular attribute could not be found in the response body.&lt;/p&gt;
&lt;h2&gt;Cause&lt;/h2&gt;
&lt;p&gt;Because SAML authentication is enabled with the default login page set to the SAML login page, all requests not containing a session cookie are expected to authenticate through SAML. Thus, the requests to the Web API are being redirected to the SAML login page rather than getting served by Appian. The&amp;nbsp;received response is the HTML of the login page of the SAML provider instead of the data&amp;nbsp;expected from the Web API. The below example illustrates the correct and erroneous responses:&lt;/p&gt;
&lt;h3&gt;Without SAML authentication&lt;/h3&gt;
&lt;pre&gt;{&lt;br /&gt;&amp;quot;output&amp;quot;: &amp;quot;No update required&amp;quot;,&lt;br /&gt;&amp;quot;success&amp;quot;: &amp;quot;true&amp;quot;&lt;br /&gt;}&lt;/pre&gt;
&lt;h3&gt;With SAML authentication&lt;/h3&gt;
&lt;pre&gt;&amp;lt;!DOCTYPE html&amp;gt;&lt;br /&gt;&amp;lt;html&amp;gt;&lt;br /&gt; &amp;lt;head&amp;gt;&lt;br /&gt; &amp;lt;meta charset=&amp;quot;utf-8&amp;quot; /&amp;gt;&lt;br /&gt; &amp;lt;/head&amp;gt;&lt;br /&gt; &amp;lt;body onload=&amp;quot;document.forms[0].submit()&amp;quot;&amp;gt;&lt;br /&gt; &amp;lt;noscript&amp;gt;&lt;br /&gt; &amp;lt;p&amp;gt;&lt;br /&gt; &amp;lt;strong&amp;gt;Note:&amp;lt;/strong&amp;gt; Since your browser does not support JavaScript,&lt;br /&gt; you must press the Continue button once to proceed.&lt;br /&gt; &amp;lt;/p&amp;gt;&lt;br /&gt; &amp;lt;/noscript&amp;gt;&lt;br /&gt; &amp;lt;form action=&amp;quot;https&amp;amp;#x3a;&amp;amp;#x2f;&amp;amp;#x2f;idp.example.com&amp;amp;#x3a;443&amp;amp;#x2f;sso&amp;amp;#x2f;SSOPOST&amp;amp;#x2f;metaAlias&amp;amp;#x2f;publicidp&amp;quot; method=&amp;quot;post&amp;quot;&amp;gt;&lt;br /&gt; &amp;lt;div&amp;gt;&lt;br /&gt; &amp;lt;input type=&amp;quot;hidden&amp;quot; name=&amp;quot;SAMLRequest&amp;quot; value=&amp;quot;PD94bWwgdmV...&amp;quot;/&amp;gt; &lt;br /&gt; &amp;lt;/div&amp;gt;&lt;br /&gt; &amp;lt;noscript&amp;gt;&lt;br /&gt; &amp;lt;div&amp;gt;&lt;br /&gt; &amp;lt;input type=&amp;quot;submit&amp;quot; value=&amp;quot;Continue&amp;quot;/&amp;gt;&lt;br /&gt; &amp;lt;/div&amp;gt;&lt;br /&gt; &amp;lt;/noscript&amp;gt;&lt;br /&gt; &amp;lt;/form&amp;gt;&lt;br /&gt; &amp;lt;/body&amp;gt;&lt;br /&gt;&amp;lt;/html&amp;gt;&lt;/pre&gt;
&lt;h2&gt;Action&lt;/h2&gt;
&lt;p&gt;Use the &lt;code&gt;?signin=native&lt;/code&gt;&amp;nbsp;query parameter in the Web API URL when making the call from the external system to enable the call to be authenticated through Basic authentication instead of SAML. For example, if the Web API URL is &lt;code&gt;https://appian.example.com/suite/webapi/get-data&lt;/code&gt;, the call should be made to&amp;nbsp;&lt;code&gt;https://appian.example.com/suite/webapi/get-data?signin=native&lt;/code&gt;.&lt;/p&gt;
&lt;h2&gt;Affected Versions&lt;/h2&gt;
&lt;p&gt;This article applies to Appian versions 17.1 through 19.1 using SAML authentication.&lt;/p&gt;
&lt;p&gt;Last Reviewed: August 2019&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: design, SAML, integration, authentication, web services, application design, web api&lt;/div&gt;
</description></item><item><title>KB-XXXX Web API calls return unexpected results after enabling SAML authentication</title><link>https://community.appian.com/support/w/kb/1502/kb-1975-web-api-calls-return-unexpected-results-after-enabling-saml-authentication/revision/2</link><pubDate>Mon, 05 Aug 2019 21:20:54 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:c7afb0bb-8831-4bb8-a11c-ebc4007e5b18</guid><dc:creator>Jussi Lundstedt</dc:creator><comments>https://community.appian.com/support/w/kb/1502/kb-1975-web-api-calls-return-unexpected-results-after-enabling-saml-authentication#comments</comments><description>Revision 2 posted to Appian Knowledge Base by Jussi Lundstedt on 8/5/2019 9:20:54 PM&lt;br /&gt;
&lt;h2&gt;Symptoms&lt;/h2&gt;
&lt;p&gt;After enabling SAML authentication for Appian, Web API calls return a &lt;code&gt;200 OK&lt;/code&gt; response code with an unexpected HTML response body that fails to parse in the external system calling the Web API. For example,&amp;nbsp;the error observed in the Web API client may indicate that the response was invalid JSON or that a particular attribute could not be found in the response body.&lt;/p&gt;
&lt;h2&gt;Cause&lt;/h2&gt;
&lt;p&gt;Because SAML authentication is enabled with the default login page set to the SAML login page, all requests not containing a session cookie are expected to authenticate through SAML. Thus, the requests to the Web API are being redirected to the SAML login page rather than getting served by Appian. The&amp;nbsp;received response is the HTML of the login page of the SAML provider instead of the data&amp;nbsp;expected from the Web API. The below example illustrates the correct and erroneous responses:&lt;/p&gt;
&lt;h3&gt;Without SAML authentication&lt;/h3&gt;
&lt;pre&gt;{&lt;br /&gt;&amp;quot;output&amp;quot;: &amp;quot;No update required&amp;quot;,&lt;br /&gt;&amp;quot;success&amp;quot;: &amp;quot;true&amp;quot;&lt;br /&gt;}&lt;/pre&gt;
&lt;h3&gt;With SAML authentication&lt;/h3&gt;
&lt;pre&gt;&amp;lt;!DOCTYPE html&amp;gt;&lt;br /&gt;&amp;lt;html&amp;gt;&lt;br /&gt; &amp;lt;head&amp;gt;&lt;br /&gt; &amp;lt;meta charset=&amp;quot;utf-8&amp;quot; /&amp;gt;&lt;br /&gt; &amp;lt;/head&amp;gt;&lt;br /&gt; &amp;lt;body onload=&amp;quot;document.forms[0].submit()&amp;quot;&amp;gt;&lt;br /&gt; &amp;lt;noscript&amp;gt;&lt;br /&gt; &amp;lt;p&amp;gt;&lt;br /&gt; &amp;lt;strong&amp;gt;Note:&amp;lt;/strong&amp;gt; Since your browser does not support JavaScript,&lt;br /&gt; you must press the Continue button once to proceed.&lt;br /&gt; &amp;lt;/p&amp;gt;&lt;br /&gt; &amp;lt;/noscript&amp;gt;&lt;br /&gt; &amp;lt;form action=&amp;quot;https&amp;amp;#x3a;&amp;amp;#x2f;&amp;amp;#x2f;idp.example.com&amp;amp;#x3a;443&amp;amp;#x2f;sso&amp;amp;#x2f;SSOPOST&amp;amp;#x2f;metaAlias&amp;amp;#x2f;publicidp&amp;quot; method=&amp;quot;post&amp;quot;&amp;gt;&lt;br /&gt; &amp;lt;div&amp;gt;&lt;br /&gt; &amp;lt;input type=&amp;quot;hidden&amp;quot; name=&amp;quot;SAMLRequest&amp;quot; value=&amp;quot;PD94bWwgdmV...&amp;quot;/&amp;gt; &lt;br /&gt; &amp;lt;/div&amp;gt;&lt;br /&gt; &amp;lt;noscript&amp;gt;&lt;br /&gt; &amp;lt;div&amp;gt;&lt;br /&gt; &amp;lt;input type=&amp;quot;submit&amp;quot; value=&amp;quot;Continue&amp;quot;/&amp;gt;&lt;br /&gt; &amp;lt;/div&amp;gt;&lt;br /&gt; &amp;lt;/noscript&amp;gt;&lt;br /&gt; &amp;lt;/form&amp;gt;&lt;br /&gt; &amp;lt;/body&amp;gt;&lt;br /&gt;&amp;lt;/html&amp;gt;&lt;/pre&gt;
&lt;h2&gt;Action&lt;/h2&gt;
&lt;p&gt;Use the &lt;code&gt;?signin=native&lt;/code&gt;&amp;nbsp;query parameter in the Web API URL when making the call from the external system to enable the call to be authenticated through Basic authentication instead of SAML. For example, if the Web API URL is &lt;code&gt;https://appian.example.com/suite/webapi/get-data&lt;/code&gt;, the call should be made to&amp;nbsp;&lt;code&gt;https://appian.example.com/suite/webapi/get-data?signin=native&lt;/code&gt;.&lt;/p&gt;
&lt;h2&gt;Affected Versions&lt;/h2&gt;
&lt;p&gt;This article applies to Appian versions 17.1 through 19.1 using SAML authentication.&lt;/p&gt;
&lt;p&gt;Last Reviewed: August 2019&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: design, SAML, integration, authentication, web services, application design, web api&lt;/div&gt;
</description></item><item><title>KB-XXXX Web API calls return unexpected results after enabling SAML authentication</title><link>https://community.appian.com/support/w/kb/1502/kb-1975-web-api-calls-return-unexpected-results-after-enabling-saml-authentication/revision/1</link><pubDate>Mon, 05 Aug 2019 15:36:16 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:c7afb0bb-8831-4bb8-a11c-ebc4007e5b18</guid><dc:creator>Jussi Lundstedt</dc:creator><comments>https://community.appian.com/support/w/kb/1502/kb-1975-web-api-calls-return-unexpected-results-after-enabling-saml-authentication#comments</comments><description>Revision 1 posted to Appian Knowledge Base by Jussi Lundstedt on 8/5/2019 3:36:16 PM&lt;br /&gt;
&lt;h2&gt;Symptoms&lt;/h2&gt;
&lt;p&gt;After enabling SAML authentication for Appian, Web API calls return a &lt;code&gt;200 OK&lt;/code&gt; response code with an unexpected response body that fails to parse in the external system calling the Web API. For example,&amp;nbsp;the error observed in the Web API client may indicate that the response was invalid JSON or that a particular attribute could not be found in the response body.&lt;/p&gt;
&lt;h2&gt;Cause&lt;/h2&gt;
&lt;p&gt;After enabling SAML authentication, the Web API is returning the HTML of the login page of the SAML provider instead of the expected data returned by the Web API.&lt;/p&gt;
&lt;h2&gt;Action&lt;/h2&gt;
&lt;p&gt;Use the &lt;code&gt;?signin=native&lt;/code&gt;&amp;nbsp;query parameter in the Web API URL when making the call from the external system to enable the call to be authenticated through Basic authentication instead of SAML. For example, if the Web API URL is &lt;code&gt;https://appian.example.com/suite/webapi/get-data&lt;/code&gt;, the call should be made to&amp;nbsp;&lt;code&gt;https://appian.example.com/suite/webapi/get-data?signin=native&lt;/code&gt;.&lt;/p&gt;
&lt;h2&gt;Affected Versions&lt;/h2&gt;
&lt;p&gt;This article applies to Appian 17.1 and later using SAML authentication.&lt;/p&gt;
&lt;p&gt;Last Reviewed: August 2019&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: design, SAML, integration, authentication, web services, application design, web api&lt;/div&gt;
</description></item></channel></rss>