On Thu, 19 Dec 2013 17:50:31 GMT, Luís Marques wrote:

Hi,

If I do a:

std.net.curl.post(someURL, "some string");

In my vibed post handler the req.bodyReader is empty, with leastSize == 0. I also couldn't find any data in the other properties of the HTTPServerRequest object that I looked. What am I doing wrong?

Luís

The reason is that CURL sends "some string" with "Content-Type: application/x-www-form-urlencoded" by default and vibe.d enables HTTPOption.parseFormBody by default, which will result in vibe.d parsing the POST body as form data which will be put into req.form. Changing either of the two should make the raw data available.