longportapp / openapi-sdk

LongPort OpenAPI SDK Base.
https://open.longportapp.com
Other
91 stars 11 forks source link

security_list API检索股票数量不全 #59

Closed shangbo closed 1 week ago

shangbo commented 2 weeks ago

问题描述 security_list API 只能检索出325只股票信息, 无法检索全部股票信息是为什么

代码例子

from longport.openapi import Config, QuoteContext, SubType, PushQuote, Market, SecurityListCategory

from  db_operation.db_init import db_init,create_session
from  orm_definition import symbol_info 

def init_config():
   #todo: token无效时自动更新逻辑
   return Config.from_env()

def fetch_stock_list():
    config = init_config()
    ctx = QuoteContext(config)
    resp = ctx.security_list(Market.US,SecurityListCategory.Overnight)
    return resp

if __name__ =='__main__':
   print(len(fetch_stock_list()))

错误信息或结果截图

image

如果可以,请给出一些执行的结果截图,最好给完整截图,避免关键信息遗漏(请注意保护你的 Access Token)

你的环境信息

sunli829 commented 2 weeks ago

目前夜盘仅开放了这些

shangbo commented 2 weeks ago

目前夜盘仅开放了这些 所以非夜盘标的,现在没有全量查询接口是吧

shangbo commented 2 weeks ago

目前夜盘仅开放了这些

有什么办法获得全量股票标的名称吗

sunli829 commented 1 week ago

目前没有接口