Add wss exmaple to create order, refactoring

This commit is contained in:
itsdeka
2023-01-11 11:51:16 +01:00
parent 876e05e9f3
commit 44ba7e780a
4 changed files with 50 additions and 3 deletions

View File

@@ -1,3 +1,5 @@
# python -c "from examples.websocket.ticker import *"
import asyncio
from bfxapi import Client, Constants
@@ -16,4 +18,4 @@ def on_t_ticker_update(subscription: Subscriptions.TradingPairTicker, data: Trad
async def open():
await bfx.wss.subscribe(Channels.TICKER, symbol="tBTCUSD")
asyncio.run(bfx.wss.start())
bfx.wss.run()