Hi,
Can you try the below code,
from fyers_api.Websocket import ws
def run_process_order_update(access_token):
data_type = "orderUpdate"
fs = ws.FyersSocket(access_token=access_token,log_path="/home/user/logs")
fs.websocket_data = custom_message
fs.subscribe(data_type=data_type)
fs.keep_running()
def custom_message(msg):
print (f"Custom:{msg}")
def main():
access_token = "SPXXXXE7-100:eyJ0eXAiOiJK***.eyJpc3MiOiJhcGkuZnllcnM***.IzcuRxg4tnXiULCx3***"
run_process_order_update(access_token)
if __name__ == '__main__':
main()