Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]
Created on 11-24-2025 04:39 PM - edited 11-24-2025 04:50 PM
Hi
What is the preferred method to alter a nifi processor configuration please?
We want to be able to get a user to choose from one of 3 options from a drop down menu in a GUI screen. The chosen option then is passed to either a curl command to make changes to the processor via the Nifi API, or can we create a python command to then alter a nifi processor configuration possibly by curl, but maybe there is another way?
Curl looks a safer option, but python might be better? Not sure....?
Thanks in advance.
Created 11-25-2025 08:56 AM
Hello @zzzz77,
The best way here should be the NiFi API. It's safer and more standardized. Also, since it's NiFi provided, it's easier to integrate.
https://nifi.apache.org/docs/nifi-docs/rest-api/index.html
You can use the Processors options.
Created on 11-26-2025 08:19 PM - edited 11-26-2025 08:32 PM
Hi,
Thanks, will do.
I did try reading Provenance data via the nifi 2.5.0 API and it seems to fail
I installed NIfi on my PC with no modifications and all default settings, and just use the default user and password that's created when you install it.
I run this in my local windows CMD window and get "unknown error" :
curl --insecure -X POST -H "Authorization: Bearer <my token> " https://localhost:8443/nifi-api/provenance
Then I run this and get :
curl --insecure -X POST -H "Authorization: Bearer <token>" https://localhost:8443/nifi-api/provenance > test.txt
In text.txt file I get :
"An unexpected error has occurred. Please check the logs for additional details."
I just wanted to check I have the syntax right. I ran other API queries for flows etc and they work fine.
What I'm trying to do is get a list of all files that have passed through my small local nifi installation so we can track what files have moved through nifi and when, as a form of monitoring.
Created 11-27-2025 09:34 AM
Hello @zzzz77,
That happens because NiFi 2.x API does not work with an empty POST on for provenance, it always needs to consume a valid JSON:
https://nifi.apache.org/docs/nifi-docs/rest-api/#provenance
You need to add the query, something like this:
curl --insecure -X POST -H "Authorization: Bearer <token>" -H "Content-Type: application/json" -d "{\"provenance\":{\"request\":{\"maxResults\":1000}}}" https://localhost:8443/nifi-api/provenance
Check in your environment.
Created 12-02-2025 07:27 AM
Hello @zzzz77,
Did the answers help you here?
If so, please consider marking the comment that help you as the solution.