tda-api
tda-api copied to clipboard
timesale_futures_subs and add_timesale_futures_handler returning data
After reading in the docs (here in the tda-api readthedocs) that these streams open but provide no data I was disappointed. But I tried them anyway. I am getting good solid futures time and sale data back from the API currently.
The data looks like it should from TDA:
{
"service": "TIMESALE_FUTURES",
"timestamp": 1636033782612,
"command": "SUBS",
"content": [
{
"seq": 0,
"key": "/ES",
"TRADE_TIME": 1636033782514,
"LAST_PRICE": 4663.25,
"LAST_SIZE": 1.0,
"LAST_SEQUENCE": 16489017
}
]
}
Just thought I would report back that it was functional. Please don't remove this from future versions on the thought that it isn't working.
Thank you for your awesomeness.
Wow! This is huge! Thanks for letting me know. Can you share the code that you used to produce this stream?
I just verified it. Too cool.
stream_client.add_timesale_futures_handler(lambda msg: print(json.dumps(msg, indent=4)))
await stream_client.timesale_futures_subs(['/ES'])
I have been trying this with multiple symbols in a list but only one comes back. What am I missing?