<?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: How to add Content-Type=application/json to InvokeHTTP in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150298#M20371</link>
    <description>&lt;P&gt;It is like this from version 0.5.0.&lt;/P&gt;</description>
    <pubDate>Tue, 23 Feb 2016 04:17:46 GMT</pubDate>
    <dc:creator>massimiliano_ni</dc:creator>
    <dc:date>2016-02-23T04:17:46Z</dc:date>
    <item>
      <title>How to add Content-Type=application/json to InvokeHTTP</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150294#M20367</link>
      <description>&lt;P&gt;I am using the InvokeHTTP processor. I need to post a json to a REST URL. I get the json via a GetFile processor, then manipulate it and finally route it to the InvokeHTTP processor. Well I get an error (412 HTTP code) because I am not able to specify teh content-type.&lt;/P&gt;&lt;P&gt;How can I do it?&lt;/P&gt;&lt;P&gt;Dynamic properties?&lt;/P&gt;&lt;P&gt;Help please,&lt;/P&gt;&lt;P&gt;Massimiliano&lt;/P&gt;</description>
      <pubDate>Sat, 20 Feb 2016 03:48:24 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150294#M20367</guid>
      <dc:creator>massimiliano_ni</dc:creator>
      <dc:date>2016-02-20T03:48:24Z</dc:date>
    </item>
    <item>
      <title>Re: How to add Content-Type=application/json to InvokeHTTP</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150295#M20368</link>
      <description>&lt;P&gt;The documentation for InvokeHttp says that Dynamic properties are sent as headers:&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH&gt;Name&lt;/TH&gt;&lt;TH&gt;Value&lt;/TH&gt;&lt;TH&gt;Description&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Header Name&lt;/TD&gt;&lt;TD&gt;Attribute Expression Language&lt;/TD&gt;&lt;TD&gt;Send request header with a key matching the Dynamic Property Key and a value created by evaluating the Attribute Expression Language set in the value of the Dynamic Property.
&lt;STRONG&gt;Supports Expression Language: true&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;So you should be able to add a property Content-Type with a value of application/json.&lt;/P&gt;&lt;P&gt;&lt;A href="https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi.processors.standard.InvokeHTTP/index.html" target="_blank"&gt;https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi.processors.standard.InvokeHTTP/index.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 20 Feb 2016 06:00:59 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150295#M20368</guid>
      <dc:creator>bbende</dc:creator>
      <dc:date>2016-02-20T06:00:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to add Content-Type=application/json to InvokeHTTP</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150296#M20369</link>
      <description>&lt;P&gt;InvokeHTTP makes use of the "mime.type" attribute.  Depending on the version you are using, this may or may not be exposed as a property "Content-Type" which defaults to the expression language "${mime.type}" &lt;/P&gt;</description>
      <pubDate>Mon, 22 Feb 2016 04:32:56 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150296#M20369</guid>
      <dc:creator>apiri</dc:creator>
      <dc:date>2016-02-22T04:32:56Z</dc:date>
    </item>
    <item>
      <title>Re: How to add Content-Type=application/json to InvokeHTTP</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150297#M20370</link>
      <description>&lt;P&gt;First of all, thank you for both answers.&lt;/P&gt;&lt;P&gt;I am working with version 0.4.&lt;/P&gt;&lt;P&gt;I have added a property "Content-Type" with a value of "application/json" and it is not worling.............should i keep the quotes?&lt;/P&gt;&lt;P&gt;Regarding the secons answer...............do you mean I have to amend the mime.type attribute to "application/json"? If so, how?&lt;/P&gt;&lt;P&gt;Thank you,&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Massimiliano&lt;/P&gt;</description>
      <pubDate>Mon, 22 Feb 2016 05:57:02 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150297#M20370</guid>
      <dc:creator>massimiliano_ni</dc:creator>
      <dc:date>2016-02-22T05:57:02Z</dc:date>
    </item>
    <item>
      <title>Re: How to add Content-Type=application/json to InvokeHTTP</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150298#M20371</link>
      <description>&lt;P&gt;It is like this from version 0.5.0.&lt;/P&gt;</description>
      <pubDate>Tue, 23 Feb 2016 04:17:46 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150298#M20371</guid>
      <dc:creator>massimiliano_ni</dc:creator>
      <dc:date>2016-02-23T04:17:46Z</dc:date>
    </item>
    <item>
      <title>Re: How to add Content-Type=application/json to InvokeHTTP</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150299#M20372</link>
      <description>&lt;P&gt;I have solved by upgrading to version 0.5.0.&lt;/P&gt;</description>
      <pubDate>Tue, 23 Feb 2016 04:18:14 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-add-Content-Type-application-json-to-InvokeHTTP/m-p/150299#M20372</guid>
      <dc:creator>massimiliano_ni</dc:creator>
      <dc:date>2016-02-23T04:18:14Z</dc:date>
    </item>
  </channel>
</rss>

