Page
Library
Module
Module type
Parameter
Class
Class type
Source
Rock.RequestSourceModule to create HTTP requests.
type t = {version : Httpaf.Version.t;target : string;headers : Httpaf.Headers.t;meth : Httpaf.Method.t;body : Body.t;env : Context.t;}makeval make :
?version:Httpaf.Version.t ->
?body:Body.t ->
?env:Context.t ->
?headers:Httpaf.Headers.t ->
string ->
Httpaf.Method.t ->
tmake ?version ?body ?env ?headers target method creates a new request from the given values.
By default, the HTTP version will be set to 1.1 and the request will not contain any header or body.
getval get :
?version:Httpaf.Version.t ->
?body:Body.t ->
?env:Context.t ->
?headers:Httpaf.Headers.t ->
string ->
tget ?version ?body ?env ?headers target creates a new GET request from the given values.
By default, the HTTP version will be set to 1.1 and the request will not contain any header or body.
postval post :
?version:Httpaf.Version.t ->
?body:Body.t ->
?env:Context.t ->
?headers:Httpaf.Headers.t ->
string ->
tpost ?version ?body ?env ?headers target creates a new POST request from the given values.
By default, the HTTP version will be set to 1.1 and the request will not contain any header or body.
putval put :
?version:Httpaf.Version.t ->
?body:Body.t ->
?env:Context.t ->
?headers:Httpaf.Headers.t ->
string ->
tput ?version ?body ?env ?headers target creates a new PUT request from the given values.
By default, the HTTP version will be set to 1.1 and the request will not contain any header or body.
deleteval delete :
?version:Httpaf.Version.t ->
?body:Body.t ->
?env:Context.t ->
?headers:Httpaf.Headers.t ->
string ->
tdelete ?version ?body ?env ?headers target creates a new DELETE request from the given values.
By default, the HTTP version will be set to 1.1 and the request will not contain any header or body.