View Source Bonfire.Common.HTTP (Bonfire v0.9.10-classic-beta.169)
Module for building and performing HTTP requests.
Summary
Functions
Makes a DELETE request
Makes a GET request
Makes a PATCH request
Makes a POST request
Makes a PUT request
Builds and perform http request.
Types
@type t() :: Bonfire.Common.HTTP
Functions
Makes a DELETE request
see request/5
Makes a GET request
see request/5
Makes a PATCH request
see request/5
Makes a POST request
see request/5
Makes a PUT request
see request/5
Builds and perform http request.
Arguments:
method
- :get, :post, :put, :delete
url
body
headers
- a keyworld list of headers, e.g. [{"content-type", "text/plain"}]
options
- custom, per-request middleware or adapter options
Returns:
{:ok, %Tesla.Env{}}
or {:error, error}