Listening to Account Updates, what triggers updates?

Hello,

My code is listening to ‘account_updates’ via the following code:

@conn.on(r’^account_updates’)
async def on_account_updates(conn, channel, account):
print(‘account’, account)

I was adding this into my algorithm because i noticed the get_account() does not always update the “cash” value as fast as i would like my loop to run. I am hoping that the WebSocket will solve this issue.

I saw this example in the documentation:

I am wondering if i can get this update every time account “cash” changes. Also, is there documentation that has the list of events that can trigger this stream?

Thank you for the help.

1 Like