<?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 Doing a POST request with a REST connector in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Doing-a-POST-request-with-a-REST-connector/m-p/1897558#M74090</link>
    <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;We're trying to set up alerting for failed /&amp;nbsp; successful tasks, by integrating with Prometheus.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Prometheus has a REST API, which we're trying to use to submit the alerts.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The curl we've used successfully from a bash prompt is:&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;curl -XPOST URL-GOES.HERE.THIS.ALL.WORKS/job/example -d $'test_metric_2 200\n'&lt;BR /&gt;&lt;BR /&gt;What's possibly of note is that without the \n the request fails. It needs a new line terminator.&lt;BR /&gt;&lt;BR /&gt;When trying to create a connector in Qlik though, I can't seem to get anything to work. Basically whatever I put as the request body, I get an 'unexpected end of input stream' error. I managed to get it to create by putting the test metric as a query parameter, but then this doesn't actually 'do' anything, we don't see anything POSTed to Prometheus like we do when we run the curl.&lt;BR /&gt;&lt;BR /&gt;Any ideas? Thanks guys.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 25 Feb 2022 09:23:03 GMT</pubDate>
    <dc:creator>rnorris</dc:creator>
    <dc:date>2022-02-25T09:23:03Z</dc:date>
    <item>
      <title>Doing a POST request with a REST connector</title>
      <link>https://community.qlik.com/t5/App-Development/Doing-a-POST-request-with-a-REST-connector/m-p/1897558#M74090</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;We're trying to set up alerting for failed /&amp;nbsp; successful tasks, by integrating with Prometheus.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Prometheus has a REST API, which we're trying to use to submit the alerts.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The curl we've used successfully from a bash prompt is:&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;curl -XPOST URL-GOES.HERE.THIS.ALL.WORKS/job/example -d $'test_metric_2 200\n'&lt;BR /&gt;&lt;BR /&gt;What's possibly of note is that without the \n the request fails. It needs a new line terminator.&lt;BR /&gt;&lt;BR /&gt;When trying to create a connector in Qlik though, I can't seem to get anything to work. Basically whatever I put as the request body, I get an 'unexpected end of input stream' error. I managed to get it to create by putting the test metric as a query parameter, but then this doesn't actually 'do' anything, we don't see anything POSTed to Prometheus like we do when we run the curl.&lt;BR /&gt;&lt;BR /&gt;Any ideas? Thanks guys.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Feb 2022 09:23:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Doing-a-POST-request-with-a-REST-connector/m-p/1897558#M74090</guid>
      <dc:creator>rnorris</dc:creator>
      <dc:date>2022-02-25T09:23:03Z</dc:date>
    </item>
  </channel>
</rss>

