Claude Skill MartBrowse skillsQuick linesLearn by videoTerminal guideWhat is a Skill?
← Back to list

China Statistics Data Query (cn-stats)

Queries China's National Bureau of Statistics public API (data.stats.gov.cn) with curl + jq to pull GDP, CPI, population and housing price index data.

Data & AnalyticsIntermediate★ 160⑂ 20AI score 8/10Last updated: Sep 15, 2026

What it does

  • Teaches Claude to hit the public API endpoints behind China's official statistics portal data.stats.gov.cn.
  • Documents the indicator-tree codes (1–14): monthly, quarterly, annual, by-province, major-city prices, HK/Macao/Taiwan, and cross-country comparisons.
  • Provides the full call chain: browse categories → search indicators → fetch region lists → query actual values.
  • Uses jq to flatten JSON responses into TSV (year / indicator / value / unit) that drops straight into tables or analysis.

Who it's for

  • Analysts, researchers and journalists tracking Chinese macro data, CPI and the property market.
  • Trade, export and market-strategy teams that need official source statistics.
  • Data engineers who prefer a public API over brittle web scraping.

Examples

  1. "Build a table of China's monthly CPI for the last three years" → resolve the monthly root node, then call stream/esData with 202301MM-202512MM.
  2. "Compare residential sales price indices for Beijing and Shanghai" → pull city codes (110000000000, 310000000000) from the major-cities list and run a multi-region query.
  3. "Search indicators for '常住人口' (permanent resident population) and fetch the annual series" → indicator search API plus the annual-data root node.

· · · Install guide · · ·

Try it now, no install

Paste this into Claude to use the skill without installing anything.

Read the instructions in this file and follow them to help me:
https://raw.githubusercontent.com/aahl/skills/HEAD/skills/cn-stats/SKILL.md

What I want: (describe your task here)

If Claude can't open the link, open it yourself and paste the contents instead.

↓ If it works for you, download the ZIP below and install it. Then it runs on its own — no pasting each time.

Install in the Claude app (no terminal)
  1. Download the ZIP with the button below.
  2. In Claude, open Settings → Capabilities and turn on 'Code execution and file creation'. (one time)
  3. Go to Customize → Skills → + → 'Upload a skill' and upload the ZIP.
↓ Download ZIP
Install in Claude Code

Let Claude do it — paste this into Claude Code

Install the skill I found on Claude Skill Mart.
Copy the skills/cn-stats folder from the GitHub repo aahl/skills into my ~/.claude/skills/cn-stats/.
When it's done, tell me in one line what this skill can do.

Install with a command instead

git clone https://github.com/aahl/skills.git && mkdir -p ~/.claude/skills && cp -r skills/skills/cn-stats ~/.claude/skills/

⚠ This is a third-party skill. Check the source repository before installing.

  1. Check prerequisites: run curl --version and jq --version. Install if missing (brew install jq on macOS, sudo apt install jq curl on Ubuntu).
  2. Create the skills folder: mkdir -p ~/.claude/skills
  3. Clone the repo: git clone https://github.com/aahl/skills.git
  4. Copy just this skill: cp -r skills/skills/cn-stats ~/.claude/skills/
  5. Restart Claude Code and try a prompt like "Get China's CPI for the last 12 months".
  6. If calls fail, the portal's API may have changed — inspect data.stats.gov.cn in your browser's Network tab and update the endpoints in SKILL.md.