Coder Social home page Coder Social logo

Comments (6)

DanRui avatar DanRui commented on August 17, 2024

from和to范围是多少,怎么传都是错误的。
image

from huobi_java.

macomfan avatar macomfan commented on August 17, 2024

您好,通过WebSocket方式订阅K线,不支持from, to参数,有效参数只有symbol和interval
Untitled

from huobi_java.

DanRui avatar DanRui commented on August 17, 2024

你好,我想获取历史K线数据,这个订阅是最新实时的K线不是我想要的。

from huobi_java.

macomfan avatar macomfan commented on August 17, 2024

不好意思,刚才看了下,新的文档里已经写了订阅方式支持历史数据,请参考https://huobiapi.github.io/docs/spot/v1/cn/#k-2

获得历史数据只能通过WebSocket的请求方式,如下
{
"req": "market.$symbol.kline.$period",
"id": "id generated by client",
"from": "from time in epoch seconds",
"to": "to time in epoch seconds"
}
现在SDK暂时不支持这种方式

from huobi_java.

DanRui avatar DanRui commented on August 17, 2024

您好,使用请求方式获取历史数据不支持自定义时间段吗,怎么传参都是不合法的。

from huobi_java.

eynzhang avatar eynzhang commented on August 17, 2024

@DanRui K线返回数据最多支持300条,您的时间段可能过大,需要调整一下时间段。

from huobi_java.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.