module http; enum HTTPMethod { GET, HEAD, POST, PUT, DELETE, CONNECT, OPTIONS, TRACE, invalid } struct HTTPRequest { HTTPMethod method; string resource; string[string] parameters; string[string] headers; string httpVersion = "HTTP/1.1"; alias path = resource; } struct HTTPResponse { string status; string[string] headers; string responseBody; string httpVersion = "HTTP/1.1"; } alias HTTPModule = HTTPResponse delegate (HTTPRequest);