Created 06-30-2022 03:20 AM
Hi Team,
I have the below flow to get the ticket details .getting 400 error and I have provided valid credentials also. Please suggest.
Note:API's working fine in postman.
Evaluation JSON path process contains access token
Update attribute processor contains the authorization
Invoke http processor contains url for ticket details.
Here I'm getting issue in invoke http processor
Created 06-30-2022 04:59 AM
Hi Team,
I am also facing same issue,Please provide the soluntion.
Created 06-30-2022 05:27 AM
@Gogineni
The dynamic property you added to the invokeHTTP processor is not using valid NiFi Expression Language (NEL). The name of your custom property "Authorization" is the header name and the evaluated NEL becomes the value to that header.
What you have is:
$.Authorization
However, the valid NEL to use to return the value from the NiFi FlowFile Attribute "Authorization" created by the earlier UpdateAttribute processor would be:
${Authorization}
If you found this response assisted with your query, please take a moment to login and click on "Accept as Solution" below this post.
Thank you,
Matt
Created on 06-30-2022 05:41 AM - edited 06-30-2022 05:42 AM
Hi ,
I have tried the property which you suggested getting below error.
Created 06-30-2022 07:14 AM
@Gogineni
Good to see that you are now getting a 401 instead of a 400.
So this becomes more of an issue with what you endpoint rest-api expects in the get method.
I am not sure what is in the content of you flowfile, but are you sure you want to send this in your GET method at this point in your dataflow? I am sure it was used earlier to fetch your access token, but probably not needed now. So try changing "Send Message Body" to "false". Also not sure how long the token you obtained is valid.
Have you tried performing the same request via curl from command line?
If you found this response assisted with your query, please take a moment to login and click on "Accept as Solution" below this post.
Thank you,
Matt
Created 07-08-2022 09:25 AM
@Gogineni had you solved this problem? if yes, would you like to share us. thanks!