Skip to main content
GET
/
v1
/
quant
/
quotes
/
ohlcv
Get OHLCV data
curl --request GET \
  --url https://api.reportify.cn/v1/quant/quotes/ohlcv \
  --header 'Authorization: Bearer <token>'
{
  "datas": [
    {}
  ],
  "metadata": {}
}

Documentation Index

Fetch the complete documentation index at: https://docs.reportify.cn/llms.txt

Use this file to discover all available pages before exploring further.

获取单只股票的 OHLCV(开高低收量)日线数据。
curl "https://api.reportify.cn/v1/quant/quotes/ohlcv?symbol=000001&market=cn&start_date=2026-01-01&end_date=2026-01-10" \
  -H "Authorization: Bearer <token>"

请求参数

symbol
string
required
股票代码
market
string
default:"cn"
股票市场:cn(A股), hk(港股), us(美股)
start_date
string
开始日期,格式:YYYY-MM-DD(默认:1 个月前)
end_date
string
结束日期,格式:YYYY-MM-DD(默认:今天)

响应参数

datas
array
OHLCV 数据列表,按日期排序
metadata
object
查询元数据

响应示例

{
  "datas": [
    {
      "market": "cn",
      "date": "2026-04-02",
      "symbol": "000001",
      "open": 10.98,
      "high": 11.02,
      "low": 10.93,
      "close": 11.0,
      "volume": 17744106,
      "amount": 194464864.8,
      "chg_percent": 0.1821,
      "turnover_rate": 0.0004,
      "pe_ttm": 12.34,
      "pe_static": 11.89,
      "pe_dynamic": 12.01,
      "is_limit_up_down": false,
      "pb": 0.8512,
      "market_cap": 213456789000.0,
      "circulating_market_cap": 198765432000.0
    },
    {
      "market": "cn",
      "date": "2026-04-01",
      "symbol": "000001",
      "open": 10.95,
      "high": 11.0,
      "low": 10.90,
      "close": 10.98,
      "volume": 15321456,
      "amount": 168123456.5,
      "chg_percent": 0.2752,
      "turnover_rate": 0.0004,
      "pe_ttm": 12.32,
      "pe_static": 11.87,
      "pe_dynamic": 11.99,
      "is_limit_up_down": false,
      "pb": 0.8498,
      "market_cap": 213123456000.0,
      "circulating_market_cap": 198456789000.0
    }
  ],
  "metadata": {
    "symbol": "000001",
    "market": "cn",
    "start_date": "2026-04-01",
    "end_date": "2026-04-10",
    "count": 2
  }
}

使用示例

获取最近行情

不传日期参数,默认获取最近 1 个月数据:
import requests

response = requests.get(
    "https://api.reportify.cn/v1/quant/quotes/ohlcv",
    headers={"Authorization": "Bearer <token>"},
    params={"symbol": "600519", "market": "cn"}
)
data = response.json()

for row in data["datas"][:5]:
    print(f"{row['date']}: 开{row['open']}{row['high']}{row['low']}{row['close']}")

获取港股数据

response = requests.get(
    "https://api.reportify.cn/v1/quant/quotes/ohlcv",
    headers={"Authorization": "Bearer <token>"},
    params={
        "symbol": "00700",
        "market": "hk",
        "start_date": "2026-01-01"
    }
)

获取美股数据

response = requests.get(
    "https://api.reportify.cn/v1/quant/quotes/ohlcv",
    headers={"Authorization": "Bearer <token>"},
    params={
        "symbol": "AAPL",
        "market": "us",
        "start_date": "2026-01-01"
    }
)

Authorizations

Authorization
string
header
required

Enter your Bearer token

Query Parameters

symbol
string
required

Stock code (e.g., 600519, 00700, AAPL)

market
enum<string>
default:cn

Stock market identifier

Available options:
cn,
hk,
us
start_date
string<date> | null
end_date
string<date> | null

Response

Successful Response

OHLCV data response.

datas
Datas · object[]
required

OHLCV data list sorted by date

metadata
Metadata · object
required

Query metadata