> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fcontext.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 市场数据

> 行情、K 线、市场状态、异动和交易日历

使用 Financial Context 的 `/api/market-data` 接口访问只读市场数据。

## 实时行情

```bash theme={null}
curl "https://openapi.fcontext.com/api/market-data/quote?symbols=AAPL.US,MSFT.US" \
  -H "x-api-key: YOUR_FCONTEXT_API_KEY"
```

## 证券静态信息

```bash theme={null}
curl "https://openapi.fcontext.com/api/market-data/quote/static_info?symbols=AAPL.US,MSFT.US" \
  -H "x-api-key: YOUR_FCONTEXT_API_KEY"
```

## K 线

```bash theme={null}
curl "https://openapi.fcontext.com/api/market-data/quote/AAPL.US/history_candlestick?period=day&count=100&adjust=none" \
  -H "x-api-key: YOUR_FCONTEXT_API_KEY"
```

常用参数：

| 参数             | 说明                                                       |
| -------------- | -------------------------------------------------------- |
| `period`       | `1m`、`5m`、`15m`、`30m`、`1h`、`day`、`week`、`month` 或 `year` |
| `count`        | 偏移模式下返回的记录数                                              |
| `start`, `end` | 日期范围模式，格式为 `YYYY-MM-DD`                                  |
| `adjust`       | `none` 或 `forward`                                       |

## 市场状态

```bash theme={null}
# 市场状态
curl "https://openapi.fcontext.com/api/market-data/market/status" \
  -H "x-api-key: YOUR_FCONTEXT_API_KEY"

# 热门异动
curl "https://openapi.fcontext.com/api/market-data/market/top_movers?market=US&count=20" \
  -H "x-api-key: YOUR_FCONTEXT_API_KEY"

# 交易日
curl "https://openapi.fcontext.com/api/market-data/market/trading_days?market=US&start=2026-01-01&end=2026-01-31" \
  -H "x-api-key: YOUR_FCONTEXT_API_KEY"
```
