Skip to content

Latest commit

 

History

History
66 lines (44 loc) · 1.92 KB

README.md

File metadata and controls

66 lines (44 loc) · 1.92 KB

ExBitstamp

Build Status Hex Version Hex docs Ebert

Elixir client library for Bitstamp HTTP API.

Installation

The package can be installed by adding ex_bitstamp to your list of dependencies in mix.exs:

def deps do
  [
    {:ex_bitstamp, "~> 0.1.0"}
  ]
end

Usage

Bitstamp API requires valid API credentials for signature generation when hitting private endpoints. By default, ExBitstamp will look for credentials in your config file:

config :ex_bitstamp,
  creds: %{
    customer_id: "customer_id",
    key: "key",
    secret: "secret"
  }

If you plan on using multiple API users and a single, default configuration doesn't work, you can pass a ExBitstamp.Credentials struct to all functions hitting private API as an optional, last argument:

alias ExBitstamp.{Credentials, CurrencyPair}

creds = %Credentials{
  customer_id: "customer_id",
  key: "key",
  secret: "secret"
}

ExBitstamp.balance(CurrencyPair.btcusd(), creds)

For a complete list of functions you can refer to documentation which can be found at https://hexdocs.pm/ex_bitstamp.

Testing

$ mix test

Security

If you discover any security related issues, please email mvrkljan@gmail.com instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.