ashareapi 0.1.0__tar.gz → 0.1.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {ashareapi-0.1.0 → ashareapi-0.1.2}/PKG-INFO +1 -1
- {ashareapi-0.1.0 → ashareapi-0.1.2}/ashareapi/__init__.py +1 -1
- {ashareapi-0.1.0 → ashareapi-0.1.2}/ashareapi/client.py +10 -0
- {ashareapi-0.1.0 → ashareapi-0.1.2}/ashareapi.egg-info/PKG-INFO +1 -1
- {ashareapi-0.1.0 → ashareapi-0.1.2}/pyproject.toml +1 -1
- {ashareapi-0.1.0 → ashareapi-0.1.2}/LICENSE +0 -0
- {ashareapi-0.1.0 → ashareapi-0.1.2}/README.md +0 -0
- {ashareapi-0.1.0 → ashareapi-0.1.2}/ashareapi/_code.py +0 -0
- {ashareapi-0.1.0 → ashareapi-0.1.2}/ashareapi/errors.py +0 -0
- {ashareapi-0.1.0 → ashareapi-0.1.2}/ashareapi.egg-info/SOURCES.txt +0 -0
- {ashareapi-0.1.0 → ashareapi-0.1.2}/ashareapi.egg-info/dependency_links.txt +0 -0
- {ashareapi-0.1.0 → ashareapi-0.1.2}/ashareapi.egg-info/requires.txt +0 -0
- {ashareapi-0.1.0 → ashareapi-0.1.2}/ashareapi.egg-info/top_level.txt +0 -0
- {ashareapi-0.1.0 → ashareapi-0.1.2}/setup.cfg +0 -0
- {ashareapi-0.1.0 → ashareapi-0.1.2}/tests/test_convert.py +0 -0
- {ashareapi-0.1.0 → ashareapi-0.1.2}/tests/test_endpoint_coverage.py +0 -0
|
@@ -13,6 +13,6 @@ from .client import AShareAPI
|
|
|
13
13
|
from .errors import (AShareError, APIError, AuthError, EmptyResultError, RateLimitError,
|
|
14
14
|
UpstreamError)
|
|
15
15
|
|
|
16
|
-
__version__ = "0.1.
|
|
16
|
+
__version__ = "0.1.2"
|
|
17
17
|
__all__ = ["AShareAPI", "AShareError", "AuthError", "RateLimitError", "EmptyResultError",
|
|
18
18
|
"UpstreamError", "APIError", "__version__"]
|
|
@@ -162,6 +162,16 @@ class AShareAPI:
|
|
|
162
162
|
"""筹码分布 / 成本"""
|
|
163
163
|
return self._get("/v1/chip", code=normalize_code(code))
|
|
164
164
|
|
|
165
|
+
def orderbook(self, code: str):
|
|
166
|
+
"""五档盘口 order book(买一~买五 / 卖一~卖五)
|
|
167
|
+
|
|
168
|
+
**秒级快照,盘中才有意义**(收盘后为当日最后快照);量单位 = **手**(×100 = 股)。
|
|
169
|
+
字段对齐 Tushare 惯例:``b1_p``/``b1_v`` ~ ``b5_p``/``b5_v``(买档价格/量)、
|
|
170
|
+
``a1_p``/``a1_v`` ~ ``a5_p``/``a5_v``(卖档)→ 装了 pandas 时可直接 ``df["b1_p"]``。
|
|
171
|
+
跌停时买档全 0 / 涨停时卖档全 0(正常现象)。
|
|
172
|
+
"""
|
|
173
|
+
return self._get("/v1/orderbook", code=normalize_code(code))
|
|
174
|
+
|
|
165
175
|
def events(self, code: str):
|
|
166
176
|
"""个股事件标签(42 类)"""
|
|
167
177
|
return self._get("/v1/events", code=normalize_code(code))
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|