T
Typebot11mo ago
Stergios

Sending an array variable via the HTTP request block

Hi, any idea how we can send arrays via the webhook body? For example, this custom body does not work (Error 500) if {{var}} is set an array, such as ["A", "B", "C"] in a previous block { "input": {{var}} } I've examined my endpoint logs and it seems that the request does sends an empty body, when {{var}} is an array. I've also tried putting quotes before and after the variable - i.e., "{{var}}", still this did not work. If you use a typical string variable, such as "A B C", the call just works.
4 Replies
Baptiste
Baptiste11mo ago
I just tried and it works on my end With a test with a webhook.site URL
Baptiste
Baptiste11mo ago
No description
Stergios
StergiosOP10mo ago
No idea why this is happening. I will investigate more. Thanks
marcipriano
marcipriano10mo ago
@Stergios How did you manage to resolve this? I need to send a json and I need to parse the variable first because if I send the direct variable it will be a string. I tried escaping it with \ but it doesn't work either!

Did you find this page helpful?