Facing issue in data retrieval from WebSocket

Hi Everyone,

I am unable to get data from websocket from past 2 days , however i am able to get historical data from APIs.

Error Message:

Error: {‘code’: 12001, ‘message’: ‘Mode change failed’, ‘s’: ‘error’}

Error: {‘type’: ‘sub’, ‘code’: 11011, ‘message’: ‘subscription failed’, ‘s’: ‘error’}

Platform: Windows 11

Python version : 3.12.4

Fyers-api-v3: 3.1.2

Please help me resolve this issue

Hey @110309383461504463692

Can you try re-generating the access token and try to run the socket once and check if the issue still persists

Hi Abhishek,

i tried again after regenerating the access token, still facing the same issue

Hey @110309383461504463692

Can you please let us know the inputs given to run the scrip

Hi @WWhYB2qrsx ,

I am running the sample script (https://github.com/FyersDev/fyers-api-sample-code/blob/sample_v3/v3/python/websocket/data_socket/data_websocket_foreground.py

) by providing the necessary details

Hi @WWhYB2qrsx ,

these are the inputs i am passing

symbols = [‘NSE:SBIN-EQ’, ‘NSE:ADANIENT-EQ’]

access_token = f"{os.environ[‘fyers_access_token’]}"

i have refreshed the token before running this script, nothing else is changed in the script as given the above github repo

is anyone going to help? its been more than 1 week now without any proper response