Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

支持获取不同时间的 K线(即支持 K线 period 自定义) #26

Open
issaTan opened this issue Jun 6, 2023 · 2 comments
Open
Labels
enhancement New feature or request

Comments

@issaTan
Copy link

issaTan commented Jun 6, 2023

原 K线 接口中 https://stock.xueqiu.com/v5/stock/chart/kline.json?symbol=NFLX&begin=1686123805473&period=1m&type=before&count=-284&indicator=kline,pe,pb,ps,pcf,market_capital,agt,ggt,balanceperiod 会根据不同的类型返回不同周期的 K线

  • 日K:day
  • 周K:week
  • 月K:month
  • 60分K:60m
  • 30分K:30m
  • 1分K:1m
    等等……

现在的 K线函数 ball.kline 只能返回 日K 是因为 pysnowball/api_ref.py 中的 klineperiod 固定为 day 了,麻烦开放传参,可以让我们获取到不同时期的 K线。

感恩作者

@bailiangjin
Copy link

kline 现在好像已经无法获取了,雪球是更改接口了么,还是加了校验

@uname-yang
Copy link
Owner

uname-yang commented Aug 5, 2024

kline 现在好像已经无法获取了,雪球是更改接口了么,还是加了校验

是验证需要多加一个uid了,可以看下README, 已经更新了。
period 参数没问题,我有时间弄下

@uname-yang uname-yang added the enhancement New feature or request label Aug 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants