Hi everyone, I have the following JSON that I need to attach to the HTTP POST request:
{
"query_input": {
"text": {
"text": "reserve a meeting room for six people",
"language_code": "en-US"
}
}
}
I tried to set the payload with that JSON with this:
Request->SetContentAsString("{\"query_input\":{\"text\":{\"language_code\":\"en - US\",\"text\":\"reserve a meeting room for six people\"}}}");
But, the response always gives me “Error 411 (Length Required); POST requests require a Content-length
header”
I tried to manually set the Content-length header manually but with no effect.
What do you think would be the problem? Isn’t there a method that lets me see what’s in the Request body before sending it? In case it would be helpful, I’m trying to replicate this example: Quickstart: Interactions with the API | Dialogflow ES | Google Cloud
Thank you in advance for the help.