'What is the method to pass a variable to body field in Uipath while using httprequest (json format)?
So, this is what I am working on UiPath..I have slack webhook.. I am POSTing using that webhook.. I have a variable "body" which is of type string.. I want to send that to slack using webhook.. In the body field, I used
"{""text"":"""+body+"""}"
And I checked the status code, it was 400.. And BodyFormat is 'application/json' I sent a normal text without any concatenation, it worked fine..
Solution 1:[1]
the body looks okay to me in how you have it.
You mentioned using POST method, but I'd double check that utilising the "PUT" method
Also check that your Accept Format is set to JSON rather than Any.
No need to change your BodyFormat as "application/json" is correct
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | craig157 |
