获取K线数据
描述
获取K线数据
HTTP请求
- GET /open/api/get_records
请求参数
| 参数名 | 参数类型 | 是否必须 | 描述 |
|---|---|---|---|
| symbol | String | 是 | 币对,例如: btcusdt |
| period | Integer | 是 | 单位为分钟,例如: 1分钟则为1,一天则为1440 |
请求示例
http
curl 'https://openapi.100ex.com/open/api/get_records?symbol=btcusdt&period=1'返回参数
| 返回字段 | 字段类型 | 字段说明 |
|---|---|---|
| data | List<Object> | [资料时间(unix timestamp), 开盘价, 最高, 最低, 收盘价, 成交量] |
返回示例
json
{
"code": "0",
"msg": "suc",
"data": [
[
1736134860,
99182.0000000000,
99213.5800000000,
99182.0000000000,
99194.9500000000,
0.8230200000
]
],
"message": null,
"traceId": null
}状态码
| 状态码 | 说明 |
|---|---|
| 0 | 成功 |
| 1 | 系统错误 |
