我正在WINAPI上写。我无法通过 websocket 接收数据。它以前有效,但发生了变化。首先,我连接到 tesnet.binancefuture.com/ws-fapi/v1 并获取监听密钥。然后我连接到stream.binance.com,但没有任何反应。我之前发过,现在显示错误。
{
"method": "REQUEST",
"params":
[
"<listenKey>@account", // request name 1
"<listenKey>@balance" // request name 2, if existing
],
"id": 12 // request ID.
}
它起作用了。
检查网址。最有可能的问题是您正在连接到stream.binance.com而不是wss://stream.binancefuture.com/ws。