<?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: Nifi API - 403 error in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/353509#M236733</link>
    <description>&lt;P&gt;You can get the id of the root process group and import the template there as well.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;André&lt;/P&gt;</description>
    <pubDate>Wed, 28 Sep 2022 10:04:55 GMT</pubDate>
    <dc:creator>araujo</dc:creator>
    <dc:date>2022-09-28T10:04:55Z</dc:date>
    <item>
      <title>Nifi API - 403 error</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/335886#M232056</link>
      <description>&lt;P&gt;I am running nifi locally using docker, I tried to generate token using the following url and obtained token successfully&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;A href="https://localhost:8443/nifi-api/access/token" target="_blank"&gt;https://localhost:8443/nifi-api/access/token&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;but when I tried to make POST call to the following URL, I received 403 error code. I used same token generated with above request, can anyone suggest what am I doing wrong?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;A href="https://localhost:8443/nifi-api/process-groups/d9a891ee-017e-1000-4067-96bceee7d5e3/template-instance" target="_blank"&gt;https://localhost:8443/nifi-api/process-groups/d9a891ee-017e-1000-4067-96bceee7d5e3/template-instance&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 09 Feb 2022 12:37:00 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/335886#M232056</guid>
      <dc:creator>Chhavi</dc:creator>
      <dc:date>2022-02-09T12:37:00Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi API - 403 error</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/336185#M232181</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/94971"&gt;@Chhavi&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please try this:&lt;/P&gt;&lt;PRE&gt;curl -X POST \&lt;BR /&gt;  -H 'Content-Type: application/x-www-form-urlencoded' \&lt;BR /&gt;  -d 'username=bob&amp;amp;password=supersecret1' \&lt;BR /&gt;  "https://nifi-1.example.org:8443/nifi-api/access/token"&lt;/PRE&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;André&lt;/P&gt;</description>
      <pubDate>Mon, 14 Feb 2022 01:24:00 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/336185#M232181</guid>
      <dc:creator>araujo</dc:creator>
      <dc:date>2022-02-14T01:24:00Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi API - 403 error</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/353457#M236713</link>
      <description>&lt;P&gt;I was facing the same response using postman and getting a 403 when calling the REST API endpoints at:&amp;nbsp;&lt;A href="https://nifi.apache.org/docs/nifi-docs/rest-api/index.html" target="_blank"&gt;https://nifi.apache.org/docs/nifi-docs/rest-api/index.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I received the token, and by default put a prefix of Bearer in front. This is not required. Now, hitting any of the GET endpoints results in a positive response.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Unfortunately there is no way at the moment of uploading templates. If there is no REST endpoint for this, how can this be done via automated pipelines?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;</description>
      <pubDate>Tue, 27 Sep 2022 16:01:42 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/353457#M236713</guid>
      <dc:creator>Kushisabishii</dc:creator>
      <dc:date>2022-09-27T16:01:42Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi API - 403 error</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/353496#M236727</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/100733"&gt;@Kushisabishii&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Which version of NiFi are you using?&lt;/P&gt;&lt;P&gt;There's an API endpoint for this: &lt;FONT face="courier new,courier"&gt;POST&amp;nbsp;/process-groups/{id}/templates/upload&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;André&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Sep 2022 07:23:07 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/353496#M236727</guid>
      <dc:creator>araujo</dc:creator>
      <dc:date>2022-09-28T07:23:07Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi API - 403 error</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/353503#M236731</link>
      <description>&lt;P&gt;Thank you for the really quick response&amp;nbsp;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/11191"&gt;@araujo&lt;/a&gt;! I'm using the latest docker container available.&lt;BR /&gt;&lt;BR /&gt;I'm new to Nifi so still working this through...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So I would have to first create a process group with: POST&amp;nbsp;&lt;SPAN&gt;/process-groups/{id}/process-groups and then follow your instructions above.&lt;BR /&gt;&lt;BR /&gt;Much appreciated!&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Sep 2022 09:14:24 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/353503#M236731</guid>
      <dc:creator>Kushisabishii</dc:creator>
      <dc:date>2022-09-28T09:14:24Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi API - 403 error</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/353509#M236733</link>
      <description>&lt;P&gt;You can get the id of the root process group and import the template there as well.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;André&lt;/P&gt;</description>
      <pubDate>Wed, 28 Sep 2022 10:04:55 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/353509#M236733</guid>
      <dc:creator>araujo</dc:creator>
      <dc:date>2022-09-28T10:04:55Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi API - 403 error</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/377337#M243230</link>
      <description>&lt;P&gt;I think you faced with NiFi Cross-Site Request Forgery Protection. Here is the link to manual: &lt;A href="https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#csrf-protection" target="_blank"&gt;https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#csrf-protection&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;When you execute authorization request (/access/token) you got two cookies: __Secure-Authorization-Bearer and __Secure-Request-Token.&lt;BR /&gt;&lt;BR /&gt;Value of __Secure-Authorization-Bearer cookie you can use as value for Authorization header or maybe your http client can add it automatically.&lt;BR /&gt;&lt;BR /&gt;And to avoid CSRF security filter you should add to all POST/PUT/DELETE requests header with name Request-Token and value of __Secure-Request-Token cookie.&lt;/P&gt;</description>
      <pubDate>Sun, 08 Oct 2023 16:43:02 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/377337#M243230</guid>
      <dc:creator>leva</dc:creator>
      <dc:date>2023-10-08T16:43:02Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi API - 403 error</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/402620#M251727</link>
      <description>&lt;P&gt;Thanks, this helped me!&lt;/P&gt;</description>
      <pubDate>Thu, 20 Feb 2025 09:48:49 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-API-403-error/m-p/402620#M251727</guid>
      <dc:creator>bl4ckp4ntherrr</dc:creator>
      <dc:date>2025-02-20T09:48:49Z</dc:date>
    </item>
  </channel>
</rss>

