query_stock
Fetch historical stock prices for A-share, Hong Kong, or US markets and save the data as a CSV file.
Instructions
Query historical stock prices for A-share, Hong Kong, or US markets. Output is written to file_path as CSV.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| freq | No | Minute granularity (period=min) | 1 |
| adjust | No | Adjustment type | qfq |
| market | Yes | Market: a (A-share), hk (Hong Kong), us (US) | |
| period | No | K-line period (min: A-share only) | daily |
| ticker | Yes | Stock ticker, e.g. 600519, 00700, AAPL | |
| end_date | Yes | End date YYYY-MM-DD | |
| file_path | Yes | Output CSV file path | |
| start_date | Yes | Start date YYYY-MM-DD |