So why is depth null?

Author: lzhqlj, Created: 2023-02-15 23:49:07, Updated: 2023-03-14 10:16:37

var  position = exchange.IO("api", "GET","/fapi/v2/positionRisk","timestamp="+Date.now()+"&symbol="+sym+"USDT")
     var trades = exchange.IO("api", "GET","/fapi/v1/trades","limit=200&timestamp="+Date.now()+"&symbol="+sym+"USDT")//获取最近成交
   var depth = exchange.IO("IO", "api", "GET","/fapi/v1/depth","timestamp="+Date.now()+"&symbol="+sym+"USDT")//获取深度

Why is the depth empty? Thank you.


More

lzhqljThank you both.

The Little Dream 是的,exchange.IO是用于调用私有函数(即需要鉴权验证的),公共函数(例如行情接口)使用HttpQuery调用。

The bone knifedepth does not require authorization, and is accessed using httpQuery ().

The Little Dream 一样的,GetAccount用的和exchange.IO一样的底层封装。

lzhqljThank you for your reply, is it faster than exchange.IO or exchange.GetAccount?

The Little Dream/upload/asset/1797fe06dd19053202dd.png This is a list of all the different ways Upload/asset/1797fe06dd19053202dd.png is credited in the database. This interface of Binance has no parameters to specify a specific asset. After you have accessed all the asset information, you can go through it to find the one you need. The balances field is an array, go through this array to identify it based on the asset.

lzhqljI'm using var position = exchange.IO (("api", "GET", "/api/v3/account") to return the information of the current account, now I want to return the request of BTC separately.