Skip to content

begaborn/bitflyer

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

bitflyer

Gem Version Circle CI Code Climate Dependency Status

bitflyer is a wrapper interface of Bitflyer lightning API

Installation

gem install bitflyer

Usage

See https://lightning.bitflyer.jp/docs for details.

HTTP API

Example

public_client = Bitflyer.http_public_client
p public_client.board # will print board snapshot
 
private_client = Bitflyer.http_private_client('YOUR_API_KEY', 'YOUR_API_SECRET')
p private_client.positions # will print your positions

Realtime API

Accessor format is like {event_name}_{product_code}. You can set lambda to get realtime events.

event_name

  • board_snapshot
  • board
  • ticker
  • executions

product_code

  • btc_jpy
  • fx_btc_jpy
  • eth_btc

Example

client = Bitflyer.realtime_client
client.ticker_btc_jpy = ->(json){ p json } # will print json object 
client.executions_btc_jpy = ->(json){ p json }
# ... 

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/unhappychoice/bitflyer. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.

License

The gem is available as open source under the terms of the MIT License.

About

bitflyer API wrapper for Ruby

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Ruby 100.0%