WS API (session.logon): Multiple accounts’ user data on a single WebSocket?

Hi,
On Spot WS API we use: wss://ws-api.binance.com/ws-api/v3session.logonuserDataStream.subscribe.

Is it possible to subscribe multiple accounts (different API keys) to user data on the same WebSocket connection?

  • We tried calling session.logon multiple times on one socket but couldn’t make it work. Is this supported or planned?
  • On Futures, is multiplexing many streams on one connection (combined stream) still recommended?

If multi-account on a single socket is not supported on Spot, can you confirm the recommended approach is “1 account = 1 WS”?
Thanks.

Hey,

  • As explained in the documentation: Note that only one API key can be authenticated. Calling session.logon multiple times changes the current authenticated API key. Therefore, it is not possible to subscribe to multiple accounts on the same WebSocket connection.
  • For Futures, a single connection can have 1024 market streams. However, only one account can be linked to each user data stream connection.

Got it, thanks for clarifying.
Even with the recent changelog update (Changelog | Binance Open Platform), does this still mean it’s not possible to have multiple Spot user-data streams on a single WebSocket connection — still one API key per connection?

It is stated in the changelog: Only one subscription per account is allowed on a single connection.
So I think it doesn’t change anything.