Logo
ClawHub Skills Lib
HomeCategoriesUse CasesTrendingBlog
HomeCategoriesUse CasesTrendingBlog
ClawHub Skills Lib
ClawHub Skills Lib

Browse 26,000+ community-built AI agent skills for OpenClaw. Updated daily from clawhub.ai.

Explore

  • Home
  • Trending
  • Use Cases
  • Blog

Categories

  • Development
  • AI & Agents
  • Productivity
  • Communication
  • Data & Research
  • Business
  • Platforms
  • Lifestyle
  • Education
  • Design

Use Cases

  • Security Auditing
  • Workflow Automation
  • Finance & Fintech
  • MCP Integration
  • Crypto Trading
  • Web3 & DeFi
  • Data Analysis
  • Social Media
  • 中文平台技能
  • All Use Cases →
© 2026 ClawHub Skills Lib. All rights reserved.Built with Next.js · Supabase · Prisma
Home/Blog/tushare-finance: 220+ Chinese Financial Data APIs for Your AI Agent
skill-spotlightfinancetushare-financeclawhubopenclawchina-stocksfinancial-dataquantitative

tushare-finance: 220+ Chinese Financial Data APIs for Your AI Agent

March 17, 2026·5 min read

With 11,800+ downloads and 110 installs, tushare-finance is the go-to financial data skill for Chinese market analysis on ClawHub. It wraps the Tushare Pro API — one of the most comprehensive free-to-use Chinese financial data platforms — giving OpenClaw agents access to 220+ data endpoints covering A-shares, H-shares, US-listed stocks, funds, futures, bonds, and macro indicators.

The Problem It Solves

Getting clean, structured Chinese financial data is surprisingly hard. Official exchange data is fragmented. Bloomberg and Wind require expensive subscriptions. Most Python finance libraries focus on US markets. Tushare Pro fills this gap — but setting up the API client, remembering 220+ endpoint names, and translating between data requirements and specific method calls takes expertise.

tushare-finance provides the expertise as a skill. Your agent knows which interface to call for each data type, what parameters to pass, and how to interpret the results.

Core Concept

The skill uses the tushare Python library with your personal Tushare Pro token. All data comes back as pandas DataFrames — the standard format for financial data analysis in Python.

import tushare as ts
 
pro = ts.pro_api()  # reads TUSHARE_TOKEN from env
 
# Any of 220+ endpoints, same pattern
df = pro.daily(ts_code='000001.SZ', start_date='20241201', end_date='20241231')

The skill's intelligence lies in knowing which of the 220+ endpoints corresponds to each data request, and translating natural language requests into the right API call.

Deep Dive

Data Categories

Tushare Pro's endpoints are organized across major categories:

CategoryEndpointsExamples
Stock Data39 endpointsDaily prices, real-time quotes, IPO calendar
Index Data18 endpointsSSE/SZSE/CSI indices, index components
Fund Data11 endpointsNAV, fund portfolio, fund manager history
FuturesMultipleDaily/minute data, position limits
BondsMultipleBond issuance, yield curve data
Macro EconomyMultipleGDP, CPI, PPI, PMI, M2, FX reserves
Financial ReportsMultipleIncome statement, balance sheet, cash flow

Stock Data — Most Used Endpoints

# Daily OHLCV for a stock
df = pro.daily(ts_code='600519.SH', start_date='20240101', end_date='20241231')
# → date, open, high, low, close, vol, amount
 
# All listed stocks
df = pro.stock_basic(exchange='', list_status='L')
# → ts_code, symbol, name, area, industry, list_date
 
# Real-time quote snapshot
df = pro.daily(ts_code='000001.SZ', trade_date='20241231')

Financial Reports

# Income statement
df = pro.income(ts_code='600036.SH', start_date='20240101', end_date='20241231')
 
# Balance sheet
df = pro.balancesheet(ts_code='600036.SH', period='20241231')
 
# Key financial indicators (ROE, ROA, PE, etc.)
df = pro.fina_indicator(ts_code='000858.SZ', start_date='20240101', end_date='20241231')

Macroeconomic Data

# GDP
df = pro.gdp(start_q='2020Q1', end_q='2024Q4')
 
# CPI — consumer price index
df = pro.cpi(start_m='202001', end_m='202412')
 
# M2 money supply
df = pro.money_supply(start_m='202001', end_m='202412')
 
# Exchange rates
df = pro.fx_daily(ts_code='USDCNY.CFETS', start_date='20240101', end_date='20241231')

Index Data

# Index daily data (CSI 300)
df = pro.index_daily(ts_code='399300.SZ', start_date='20240101', end_date='20241231')
 
# Index components (who's in the CSI 300 right now)
df = pro.index_weight(index_code='399300.SZ', trade_date='20241231')

Stock Code Format

A critical convention: Tushare uses ts_code format — {symbol}.{exchange}:

ExchangeCodeExample
Shanghai Stock Exchange.SH600519.SH (Kweichow Moutai)
Shenzhen Stock Exchange.SZ000001.SZ (Ping An Bank)
Beijing Stock Exchange.BJ430047.BJ
Hong Kong.HK00700.HK (Tencent)

Dates use YYYYMMDD format (no dashes): 20241231, not 2024-12-31.

Setup

clawhub install tushare-finance

Get your Tushare token at tushare.pro (free registration):

export TUSHARE_TOKEN="your_tushare_token_here"

Verify the Python dependencies:

python -c "import tushare, pandas; print('OK')"
# If missing: pip install tushare pandas

Comparison: Chinese Financial Data Sources

SourceCostCoverageAPI QualityAgent-native
tushare-financeFree (Tushare Pro)A+H+US+macro✅ pandas✅
Wind (万得)¥10,000+/yearComprehensive✅❌
Bloomberg$2,000+/monthGlobal✅❌
akshare (Python lib)FreeA-share focus✅⚠️ no skill
Raw exchange dataFreeLimited❌ complex❌

Tushare Pro's free tier has rate limits and some premium endpoints require points (earned through community contribution), but the free tier covers the most commonly needed data.

Practical Tips

  1. Cache heavy queries — historical data doesn't change; save DataFrames locally to avoid hitting rate limits on repeated analysis
  2. Use stock_basic() first — always start by fetching the full stock list to validate ts_codes before querying price data
  3. Date format discipline — YYYYMMDD throughout, no exceptions; wrong format returns empty DataFrames without error
  4. Batch by date, not by stock — Tushare's trade_date parameter returns all stocks for that date; more efficient than looping per stock
  5. Points system awareness — some advanced endpoints (e.g., Lv2 data, institutional holdings) require Tushare points; check endpoint documentation before relying on them

Considerations

  • Rate limits on free tier: Tushare Pro's free tier allows ~200 calls/minute. Heavy backtesting or large-scale screening may hit limits.
  • Historical depth varies: Most equity data goes back to 2000+; some macro indicators have shorter history.
  • Data quality: Tushare Pro is community-maintained. Occasional gaps or adjustments exist, especially around corporate actions (splits, dividends). Always validate critical data points.
  • Mainland China focus: While H-share and US data is available, depth and frequency is strongest for A-share markets.

The Bigger Picture

Chinese financial markets are the second-largest in the world, yet English-language tooling and AI agents overwhelmingly default to US market data. tushare-finance corrects this gap — giving agents access to the same data that Chinese quant funds and analysts use, without expensive subscriptions or custom API integrations.

For agents doing portfolio analysis, earnings research, or macroeconomic modeling with a China focus, this skill is the foundation everything else builds on.


View the skill on ClawHub: tushare-finance

← Back to Blog