Skip to content

Straightforward API endpoint to receive market data for Binance Futures.

License

Notifications You must be signed in to change notification settings

philipperemy/binance-futures

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Binance Futures

Straightforward API endpoint to receive market data for Binance Futures.

Installation

Recommended to use a virtual environment. Only tested with Python 3.

pip install binance-future

Example

from binance_futures import BinanceFuturesBBO

bbo = BinanceFuturesBBO(symbols=['btcusdt', 'ethusdt', 'ltcusdt'])

# prints the bid/ask of BTCUSDT along with its volumes (best bid offer).
print(bbo.ticker('btcusdt'))

# futures | btcusdt | 0.9230 @ 58875.57 | 0.0040 @ 58875.58

# prints any ticker update for the future instruments defined above.
bbo.print_on_ticker_update()

# futures | btcusdt | 0.9230 @ 58875.57 | 0.0040 @ 58875.58
# futures | ltcusdt | 2.2270 @ 207.15 | 28.5200 @ 207.16

About

Straightforward API endpoint to receive market data for Binance Futures.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages