Specifying data to post when not using the onSend callback.
The data is NOT copied by the library. Content-Type will default to application/octet-stream. Data is not converted or encoded by this method.
import std.net.curl, std.stdio, std.conv; auto http = HTTP("http://www.mydomain.com"); http.onReceive = (ubyte[] data) { writeln(to!(const(char)[])(data)); return data.length; }; http.postData = [1,2,3,4,5]; http.perform();
See Implementation
Specifying data to post when not using the onSend callback.
The data is NOT copied by the library. Content-Type will default to application/octet-stream. Data is not converted or encoded by this method.