Merchant.Client (Merchant v0.2.0)

View Source

Client for the Merchant API.

Summary

Types

error()

@type error() :: {:error, Tesla.Env.t()}

method()

@type method() :: :head | :get | :delete | :trace | :options | :post | :put | :patch

Functions

client()

@spec client() :: Tesla.Client.t()

req(method, path, body \\ nil, params \\ [], headers \\ [], opts \\ [])

@spec req(method(), String.t(), term(), Keyword.t(), Keyword.t(), Keyword.t()) ::
  {:ok, term()} | error()

req!(method, path, body \\ nil, params \\ [], headers \\ [], opts \\ [])

@spec req!(method(), String.t(), term(), Keyword.t(), Keyword.t(), Keyword.t()) ::
  term()