HTTPClient

Minimalistic HTTP client. At this point it only support simple GET requests which return the whole response body.

Constructors

this
this(string userAgent)

Creates a HTTP client with user-specified User-Agent.

Destructor

~this
~this()
Undocumented in source.

Members

Functions

GET
HTTPResponse GET(URI uri)

Perform a HTTP GET request.

HEAD
HTTPResponse HEAD(URI uri)

Perform a HTTP HEAD request (same as GET but without content).

close
void close()
Undocumented in source. Be warned that the author may not have intended to support it.
request
HTTPResponse request(HTTPMethod method, URI uri, string[string] headers)

Performs a HTTP request. Requested URI can be "*", an absolute URI, an absolute path, or an authority depending on the method.

Bugs

We might need to pool TCP connections later on.

Meta