Support Questions
Find answers, ask questions, and share your expertise

NiFi design to include REST auth in SQL to JSON to HTTP POST

New Contributor

Hi All.

 

I'm relatively new to NiFi and would like a little help in designing a data flow that looks like this:

 

  1. SELECT from a SQL data source
  2. split/convert to JSON
  3. optionally transform JSON
  4. merge to 500 record batches
  5. POST to target via REST API (requires session token from API auth POST)

I know how to create this flow in NiFi. The part I'm having trouble with is including a step that gets a session token via the REST API auth endpoint. I can get the session token using InvokeHTTP no problem. I just don't know how to add the session token to the flow file(s) containing the data to POST to the API.

 

Thanks for your help.

1 ACCEPTED SOLUTION

Master Collaborator

Hi, @abhai ,

 

Please check my response to this question. It may also address yours.

 

Regards,

André

--
Was your question answered? Please take some time to click on "Accept as Solution" below this post.
If you find a reply useful, say thanks by clicking on the thumbs up button.

View solution in original post

2 REPLIES 2

Master Collaborator

Hi, @abhai ,

 

Please check my response to this question. It may also address yours.

 

Regards,

André

--
Was your question answered? Please take some time to click on "Accept as Solution" below this post.
If you find a reply useful, say thanks by clicking on the thumbs up button.

New Contributor

Hi @araujo ,

 

This is exactly what I was looking for. Thanks very much!

; ;