So I’m literally just trying to the very first thing (for reference I’ve built my algo platform using the TDA api but I don’t want to use schwab and also it’s not that good), however with that API I can just get a bid price by inputing a ticker. For this, it seems I should be using the streaming function (which I recognize is a better solution), when I try to test it out by just doing this:
from alpaca.data.live import StockDataStream
wss_client = StockDataStream(key,key)
async def quote_data_handler(data: Any):
print(data)
wss_client.subscribe_quotes(quote_data_handler, “SPY”)
wss_client.run()
which comes directly from these docs: Market Data - Alpaca-py
but it just tells me that “Any” is not defined which is true. Either I’m using an outdated version of python (possible) or I’m missing something else…
Anyone help me get started?