<?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 Web Services - 302 Redirect in Product Forum</title>
    <link>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100567#M47800</link>
    <description>Hello - am currently building a Web Service that pings a central server in order to get a) a redirect URL and b) a JWT token. I am able to send the request and get a 302 code back, but it comes up as an internal error rather than populating the HTTP Status Code and Response Headers data items as expected.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;If we get a 200 OK back it populates them, but I can't seem to find a way to get it to be okay with a 302 as this is what we want to get back when making this API call - please help!</description>
    <pubDate>Wed, 03 Aug 2022 09:25:11 GMT</pubDate>
    <dc:creator>MaxGent</dc:creator>
    <dc:date>2022-08-03T09:25:11Z</dc:date>
    <item>
      <title>Web Services - 302 Redirect</title>
      <link>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100567#M47800</link>
      <description>Hello - am currently building a Web Service that pings a central server in order to get a) a redirect URL and b) a JWT token. I am able to send the request and get a 302 code back, but it comes up as an internal error rather than populating the HTTP Status Code and Response Headers data items as expected.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;If we get a 200 OK back it populates them, but I can't seem to find a way to get it to be okay with a 302 as this is what we want to get back when making this API call - please help!</description>
      <pubDate>Wed, 03 Aug 2022 09:25:11 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100567#M47800</guid>
      <dc:creator>MaxGent</dc:creator>
      <dc:date>2022-08-03T09:25:11Z</dc:date>
    </item>
    <item>
      <title>Re: Web Services - 302 Redirect</title>
      <link>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100568#M47801</link>
      <description>&lt;P&gt;Hi Max,&lt;BR /&gt;&lt;BR /&gt;This is possible but how you handle errors may need to change.&lt;BR /&gt;&lt;BR /&gt;Because it's not a 200 result it may be getting classed as a "failure" despite it being positive if the return is a 302.&lt;BR /&gt;&lt;BR /&gt;What you can do is inside your process or retry loop if you work in a pathway to read the exception message and see if "302" is in the test with an InString( call.&lt;BR /&gt;If it is in the exception message then you can return to the happy path. If it was a 400 exception e.g. invalid password, then you can throw the exception as normal.&amp;nbsp;&lt;BR /&gt;Example below&lt;/P&gt;
&lt;DIV class="media" style="overflow: hidden; zoom: 1;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="36522.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/36540i3A520197A20A716F/image-size/large?v=v2&amp;amp;px=999" role="button" title="36522.png" alt="36522.png" /&gt;&lt;/span&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 03 Aug 2022 14:19:17 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100568#M47801</guid>
      <dc:creator>RonanConsidine</dc:creator>
      <dc:date>2022-08-03T14:19:17Z</dc:date>
    </item>
    <item>
      <title>Re: Web Services - 302 Redirect</title>
      <link>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100569#M47802</link>
      <description>Thanks for this Ronan - how can we then get the data from the response headers once we've handled the 302 error?</description>
      <pubDate>Wed, 03 Aug 2022 15:15:06 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100569#M47802</guid>
      <dc:creator>MaxGent</dc:creator>
      <dc:date>2022-08-03T15:15:06Z</dc:date>
    </item>
    <item>
      <title>Re: Web Services - 302 Redirect</title>
      <link>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100570#M47803</link>
      <description>&lt;P&gt;Hi Max, if you look at the response content when you generate the 302 error are you able to see the full detail or is it just an error message?&lt;/P&gt;
&lt;P&gt;You should be able to add 1 or many calculation stages to read the data into a suitable collection. If you are able to send an example or a safe data example I might be able to help you more.&lt;BR /&gt;Another tool that might help you with responses it Postman, it's free to set up and you can see the full response with any response so you can set the outputs in BluePrism to different headers if they are available.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Aug 2022 16:21:16 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100570#M47803</guid>
      <dc:creator>RonanConsidine</dc:creator>
      <dc:date>2022-08-03T16:21:16Z</dc:date>
    </item>
    <item>
      <title>Re: Web Services - 302 Redirect</title>
      <link>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100571#M47804</link>
      <description>Hi &lt;a href="https://community.blueprism.com/t5/user/viewprofilepage/user-id/36486"&gt;@MaxGent&lt;/a&gt;,&lt;BR /&gt;&lt;BR /&gt;Am I correct in thinking that you're using the &lt;STRONG&gt;Web API Service&lt;/STRONG&gt; feature to build this? If so, you probably won't have access to the headers as I don't believe BP includes them in the exception detail. This is one of my gripes about this feature. If the response is anything other than an HTTP 2xx code, Blue Prism treats it as an exception and things become challenging.&lt;BR /&gt;&lt;BR /&gt;What I've started doing is simply using the &lt;STRONG&gt;Utility - HTTP&lt;/STRONG&gt; VBO to perform all but the absolute most basic HTTP/REST actions. The HTTP VBO gives you significantly more control over the request/response handling.&lt;BR /&gt;&lt;BR /&gt;Cheers,&lt;BR /&gt;Eric​</description>
      <pubDate>Wed, 03 Aug 2022 18:08:23 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100571#M47804</guid>
      <dc:creator>ewilson</dc:creator>
      <dc:date>2022-08-03T18:08:23Z</dc:date>
    </item>
    <item>
      <title>Re: Web Services - 302 Redirect</title>
      <link>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100572#M47805</link>
      <description>Hi Eric,&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Thanks for this - that's really frustrating, but we'll go ahead and build an object for this instead to cover each API call. Is there a way to feed this into the dev team? It feels like a fairly fundamental feature...&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Hi Ronan,&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Thanks for your help on this, but as Eric mentioned we need the headers specifically as the content is empty (as expected).</description>
      <pubDate>Thu, 04 Aug 2022 07:02:58 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100572#M47805</guid>
      <dc:creator>MaxGent</dc:creator>
      <dc:date>2022-08-04T07:02:58Z</dc:date>
    </item>
    <item>
      <title>Re: Web Services - 302 Redirect</title>
      <link>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100573#M47806</link>
      <description>When I'm trying to put in headers (namely Content-Length) into the HTTP Request, I keep getting the below error:&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="36523.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/36533iA4C4103BE37C4C06/image-size/large?v=v2&amp;amp;px=999" role="button" title="36523.png" alt="36523.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="36524.png"&gt;&lt;img src="https://community.blueprism.com/t5/image/serverpage/image-id/36534i58C936A3F79074EC/image-size/large?v=v2&amp;amp;px=999" role="button" title="36524.png" alt="36524.png" /&gt;&lt;/span&gt;</description>
      <pubDate>Thu, 04 Aug 2022 09:21:47 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100573#M47806</guid>
      <dc:creator>MaxGent</dc:creator>
      <dc:date>2022-08-04T09:21:47Z</dc:date>
    </item>
    <item>
      <title>Re: Web Services - 302 Redirect</title>
      <link>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100574#M47807</link>
      <description>Hi &lt;a href="https://community.blueprism.com/t5/user/viewprofilepage/user-id/36486"&gt;@MaxGent&lt;/a&gt;,&lt;BR /&gt;&lt;BR /&gt;Regarding the Web API feature, there are several open enhancement requests on it. I believe you can find some of them on the Ideas page.&lt;BR /&gt;&lt;BR /&gt;As for the Content-Length header, are you using the &lt;EM&gt;&lt;STRONG&gt;HTTP Request&lt;/STRONG&gt;&lt;/EM&gt; action or one of the others? Generally, Content-Length doesn't need to be provided unless you're using the&lt;EM&gt;&lt;STRONG&gt; HTTP Request Multipart&lt;/STRONG&gt;&lt;/EM&gt; action. This leads me to another question. Are you using the latest release of the &lt;STRONG&gt;Utility - HTTP&lt;/STRONG&gt; VBO? If not, you can get it from the Digital Exchange at the link below:&lt;BR /&gt;&lt;BR /&gt;&lt;A href="https://digitalexchange.blueprism.com/dx/entry/3439/solution/utility---http" target="_blank" rel="noopener"&gt;https://digitalexchange.blueprism.com/dx/entry/3439/solution/utility---http&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Cheers,&lt;BR /&gt;Eric​</description>
      <pubDate>Thu, 04 Aug 2022 11:42:18 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/Web-Services-302-Redirect/m-p/100574#M47807</guid>
      <dc:creator>ewilson</dc:creator>
      <dc:date>2022-08-04T11:42:18Z</dc:date>
    </item>
  </channel>
</rss>

