I created several futures orders, they were filled, and now I want to check their status through listenkey
from binance.client import Client
import websocket, json
api_key = MY_API_KEY
api_secret = MY_API_SECRET
client = Client(api_key, api_secret)
listen_key = client.futures_stream_get_listen_key()
socket = f'wss://fstream.binance.com/ws/{listen_key}'
def on_message(ws,message):
data = json.loads(message)
print(data)
def on_close(ws, close_status_code, close_msg):
print("### closed ###")
ws = websocket.WebSocketApp(socket, on_close=on_close, on_message=on_message)
ws.run_forever()
But I don't get any information what is the reason?
[link] [comments]
You can get bonuses upto $100 FREE BONUS when you:
π° Install these recommended apps:
π² SocialGood - 100% Crypto Back on Everyday Shopping
π² xPortal - The DeFi For The Next Billion
π² CryptoTab Browser - Lightweight, fast, and ready to mine!
π° Register on these recommended exchanges:
π‘ Binanceπ‘ Bitfinexπ‘ Bitmartπ‘ Bittrexπ‘ Bitget
π‘ CoinExπ‘ Crypto.comπ‘ Gate.ioπ‘ Huobiπ‘ Kucoin.
Comments