View Source BitcoinCoreClient.Rpc.Http behaviour (BitcoinCoreClient v0.1.2)

Wrapper around HTTPoison to allow testable RPC calls over HTTP

Link to this section Summary

Functions

Sends a POST request over HTTP and returns the parsed result

Starts the HTTP client

Link to this section Callbacks

Link to this callback

post!(binary, binary, list)

View Source
@callback post!(binary(), binary(), list()) :: any()
@callback start() :: any()

Link to this section Functions

Link to this function

post!(url, post_body, headers)

View Source
@spec post!(binary(), binary(), list()) :: any()

Sends a POST request over HTTP and returns the parsed result

@spec start() :: {:ok, [atom()]} | {:error, map()}

Starts the HTTP client

examples

Examples

iex> BitcoinCoreClient.Rpc.Http.start()
{:ok, []}