Hello guys,
I am trying to use C++ to interact with my DB. While I am trying to use POST request to send my query, it seems the API cannot capture my parameters. Specifically, it always return 400 bad request. error message is {“error”: “missing required parameter \ “q””}
In the code, I have something like
/header part/
“POST /query http/1.1\r\n”
/other parts of header/
"/r/n/r/n" /* end of header*/
/request body/
“q=show+databases” or “q=show+databases” //won’t work, return 400
I have also tried to use jaon format as string, however, all of them will return me the aforementioned error. I am wondering if someone can help me with this please? Thank you!!!