View Source Sanity.Behaviour behaviour (sanity v2.0.0)
Behaviour implemented by the Sanity module. This behaviour includes all functions that make
requests to the Sanity API. Pure functions from the Sanity module are not included. This
behaviour is useful for creating mocks using the Mox library.
Summary
Callbacks
@callback request( Sanity.Request.t(), keyword() ) :: {:ok, Sanity.Response.t()} | {:error, Sanity.Response.t()}
@callback request!( Sanity.Request.t(), keyword() ) :: Sanity.Response.t()
@callback stream(Keyword.t()) :: Enumerable.t()