pagantis_elixir_tools v0.20.0 ElixirTools.HttpClient.Request behaviour

A Request prepares and does the call to an external provider.

Link to this section Summary

Types

The parameters to build the request.

The return for every request.

Link to this section Types

Link to this type

params()

params() :: map()

The parameters to build the request.

Link to this type

request_opt()

request_opt() :: []
Link to this type

request_return()

request_return() :: {:ok, atom() | json()} | {:error, json()}

The return for every request.

Link to this section Callbacks

Link to this callback

create(params, request_opt)

(optional)
create(params(), request_opt()) :: request_return()

Execute an action on a resource

Link to this callback

delete(params, request_opt)

(optional)
delete(params(), request_opt()) :: request_return()
Link to this callback

get(params, request_opt)

(optional)
Link to this callback

update(params, request_opt)

(optional)
update(params(), request_opt()) :: request_return()