Bitso Ruby GEM
This is the official client library for the Bitso API v2. We provide an intuitive, stable interface to integrate Bitso into your Ruby project.
Installation
Add this line to your application's Gemfile:
gem 'bitso'
Then execute:
bundle install
Or install it yourself as:
gem install bitso
Authentication
Create API Key
More info at: https://bitso.com/api_setup
Setup
require 'bitso'
client = Bitso.new(CLIENT, API_KEY, API_SECRET)
Our API returns Floats by default. However, we recommend you override this option and use BigDecimals instead to avoid loss of precision. In order to do this, you can pass the precise: true
parameter to the Bitso client:
require 'bitso'
client = Bitso.new(CLIENT, API_KEY, API_SECRET, precise: true)
Usage
=======
Ticker
The Bitso ticker. Returns last
, high
, low
, volume
, bid
and ask
client.ticker
client.ticker.low # => "3500.17"
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request