ExGram.Adapter behaviour (ex_gram v0.25.0) View Source

Behaviour for HTTP adapters

Link to this section Summary

Link to this section Types

Specs

body() :: map() | list()

Specs

path() :: String.t()

Specs

result_request() :: {:ok, map()} | {:error, ExGram.Error.t()}

Specs

verb() :: :post | :get

Link to this section Callbacks

Link to this callback

request(verb, path, body)

View Source

Specs

request(verb(), path(), body()) :: result_request()