Hi All,
I am just starting and trying to subscribe to stream. I am using the following script
from alpaca.data.live import StockDataStream
API_KEY = “key”
SECRET = “secret”
STOCK_LIST = [ *
** “ABSI”, **
** “ACCD”, **
** “AFRM”, **
** “AI”*
** ]**
wss_client = StockDataStream(API_KEY, SECRET, url_override = “wss://stream.data.alpaca.markets/v1.1/iex”)
# async handler
async def quote_data_handler(data):
** # quote data will arrive here**
** print(data)**
*wss_client.subscribe_quotes(quote_data_handler, STOCK_LIST)
wss_client.run()
I am just getting the following error repeatedly
data websocket error, restarting connection: server rejected WebSocket connection: HTTP 404
I tried different url_override and got the same error
“wss://stream.data.alpaca.markets/v1.1/iex”
“wss://stream.data.alpaca.markets/v2/iex”
“wss://stream.data.alpaca.markets/v1/iex”
“wss://stream.data.alpaca.markets/v1.1/test”
“wss://stream.data.alpaca.markets/v2/test”
“wss://stream.data.alpaca.markets/v1/test”
Am I doing something wrong?