<?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 NiFi rest api creating parameter context in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/NiFi-rest-api-creating-parameter-context/m-p/333390#M231431</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I noticed that in NiFi rest api documentation for version &lt;A title="NiFi rest api 1.9.0" href="https://nifi.apache.org/docs/nifi-docs/components/nifi-docs/rest-api/index.html" target="_self"&gt;1.9.0&lt;/A&gt; the parameter context endpoints have been removed, even though they existed in version &lt;A title="NiFi rest api 1.15.2" href="https://nifi.apache.org/docs/nifi-docs/rest-api/index.html" target="_self"&gt;1.15.2&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MeAndB_0-1641707745629.png" style="width: 400px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/33109iBBA0DD09E74AE177/image-size/medium?v=v2&amp;amp;px=400" role="button" title="MeAndB_0-1641707745629.png" alt="MeAndB_0-1641707745629.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Furthermore, I am using NiFi version 1.13.2 and I can see that in my browser's debugging tools, in the network tab, whenever I create a parameter context, a post request is sent to&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;A href="http://localhost:8080/nifi-api/parameter-contexts:" target="_blank"&gt;http://localhost:8080/nifi-api/parameter-contexts:&lt;/A&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MeAndB_1-1641707973797.png" style="width: 400px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/33110i8327DEC51D56E929/image-size/medium?v=v2&amp;amp;px=400" role="button" title="MeAndB_1-1641707973797.png" alt="MeAndB_1-1641707973797.png" /&gt;&lt;/span&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;and the following payload is being sent :&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;{
    "component": {
        "name": "aaaaaaaaaaa",
        "description": "aaaaaaaaaaaaaaaa",
        "parameters": []
    },
    "revision": {
        "clientId": "3d3697c2-017e-1000-0610-31b28073cf9b",
        "version": 0
    }
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The parameter context is successfully created. However when I attempt to send a post request from an external API or even hit the previously mentioned endpoint through the browser using the same payload, I get:&lt;/P&gt;&lt;PRE&gt;HTTP 405 Method Not Allowed&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;My questions are:&lt;/P&gt;&lt;P&gt;1. Is anyone aware whether these endpoints have been removed/restricted intentionally?&lt;/P&gt;&lt;P&gt;2. If they are not remove/restricted, has anyone been able to successfully send a post request and create a parameter context through NiFi's rest api?&lt;/P&gt;</description>
    <pubDate>Sun, 09 Jan 2022 06:06:26 GMT</pubDate>
    <dc:creator>MeAndB</dc:creator>
    <dc:date>2022-01-09T06:06:26Z</dc:date>
    <item>
      <title>NiFi rest api creating parameter context</title>
      <link>https://community.cloudera.com/t5/Support-Questions/NiFi-rest-api-creating-parameter-context/m-p/333390#M231431</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I noticed that in NiFi rest api documentation for version &lt;A title="NiFi rest api 1.9.0" href="https://nifi.apache.org/docs/nifi-docs/components/nifi-docs/rest-api/index.html" target="_self"&gt;1.9.0&lt;/A&gt; the parameter context endpoints have been removed, even though they existed in version &lt;A title="NiFi rest api 1.15.2" href="https://nifi.apache.org/docs/nifi-docs/rest-api/index.html" target="_self"&gt;1.15.2&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MeAndB_0-1641707745629.png" style="width: 400px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/33109iBBA0DD09E74AE177/image-size/medium?v=v2&amp;amp;px=400" role="button" title="MeAndB_0-1641707745629.png" alt="MeAndB_0-1641707745629.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Furthermore, I am using NiFi version 1.13.2 and I can see that in my browser's debugging tools, in the network tab, whenever I create a parameter context, a post request is sent to&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;A href="http://localhost:8080/nifi-api/parameter-contexts:" target="_blank"&gt;http://localhost:8080/nifi-api/parameter-contexts:&lt;/A&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MeAndB_1-1641707973797.png" style="width: 400px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/33110i8327DEC51D56E929/image-size/medium?v=v2&amp;amp;px=400" role="button" title="MeAndB_1-1641707973797.png" alt="MeAndB_1-1641707973797.png" /&gt;&lt;/span&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;and the following payload is being sent :&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;{
    "component": {
        "name": "aaaaaaaaaaa",
        "description": "aaaaaaaaaaaaaaaa",
        "parameters": []
    },
    "revision": {
        "clientId": "3d3697c2-017e-1000-0610-31b28073cf9b",
        "version": 0
    }
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The parameter context is successfully created. However when I attempt to send a post request from an external API or even hit the previously mentioned endpoint through the browser using the same payload, I get:&lt;/P&gt;&lt;PRE&gt;HTTP 405 Method Not Allowed&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;My questions are:&lt;/P&gt;&lt;P&gt;1. Is anyone aware whether these endpoints have been removed/restricted intentionally?&lt;/P&gt;&lt;P&gt;2. If they are not remove/restricted, has anyone been able to successfully send a post request and create a parameter context through NiFi's rest api?&lt;/P&gt;</description>
      <pubDate>Sun, 09 Jan 2022 06:06:26 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/NiFi-rest-api-creating-parameter-context/m-p/333390#M231431</guid>
      <dc:creator>MeAndB</dc:creator>
      <dc:date>2022-01-09T06:06:26Z</dc:date>
    </item>
    <item>
      <title>Re: NiFi rest api creating parameter context</title>
      <link>https://community.cloudera.com/t5/Support-Questions/NiFi-rest-api-creating-parameter-context/m-p/333391#M231432</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I figured it out. It had to do with me not serialising the data to json properly before passing it as json and also I should have used the following for the header:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;headers={"Content-type": "application/json", "Accept": "application/json"}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Also, this means, that even though the parameter context endpoints are not listed in version 1.9.0., they are still available.&lt;/P&gt;</description>
      <pubDate>Sun, 09 Jan 2022 09:03:48 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/NiFi-rest-api-creating-parameter-context/m-p/333391#M231432</guid>
      <dc:creator>MeAndB</dc:creator>
      <dc:date>2022-01-09T09:03:48Z</dc:date>
    </item>
  </channel>
</rss>

