It is easy to set POST parameters for HTTP request.
The Flow Diagram

Steps To Set Get Parameters
1) Inject Node
– Payload – can set to anything. In my case I use timestamp

2) Function Node
– Set POST parameters value here
– msg.headers must set the content type.
– All the POST parameters are set inside msg.payload and the parameter names must correspond to RESTFUL API that you query.
1 2 3 4 5 6 7 |
msg.headers={ 'Content-Type': 'application/x-www-form-urlencoded' }; msg.payload = {}; msg.payload={ 'ID': 1159 }; |
3) HTTP Request Node
– Choose method: POST
– Set the correspondent RESTFUL endpoint.

4) Debug Node
– Use to display the output

Notes:
Node Red version used – v0.20.7