Links

市场深度数据

1. 接口调用:
https://{host}/marketApi/depth
2. 请求参数实例
参数
是否必须
说明
channelId
渠道id
timestamp
毫秒时间戳(UTC+8)
sign
签名
tradePair
交易对
depth
深度聚合,取值1,2,3,4,5,6
3.请求参数示例
{
"channelId":"swft-channel",
"sign":"102027D292DD0707E0D899459D91C759858D7367D223CB239A8EC3A90C30B122",
"timestamp":"1557653925555",
"tradePair":"BTC/USDT",
"depth":"1"
}
4.返回结果示例
{
"data":{
"buyOrders":[
[
"10395.67",
"0.006137"
],
[
"10393.50",
"4.741722"
]
],
"sellOrders":[
[
"10392.33",
"0.097679"
],
[
"10392.39",
"1.593146"
]
],
"latestPrice":"10392.33",
"latestType":"buy"
},
"resCode":"800",
"resMsg":"成功"
}
5.返回参数说明
字段名称
是否数组
字段
数据类型
数据长度
必须项
备注
当前买单
Y
buyOrders
Array
-
Y
eg: array
当前卖单
Y
sellOrders
Array
-
Y
eg: array
最新价格
N
latestPrice
String
20
Y
eg: 10392.33
最新交易类型
N
latestType
String
20
Y
eg: sell/buy