What it does
查询 A 股、美股、港股与场内基金行情,并通过 Node.js、浏览器、CLI 或 MCP 快速接入。
- Connects Instruction files the AI reads
- Account or key No key found in README or SKILL.md
- Category Other
For makers: add a badge to your README
If you made this, paste this code into your README. The badge links back to this page.
[](https://mcp.popnx.com/en/skills/zhangxiangliang-stock-api)Similar Skills
Same kind of work, ordered like the Skills list
| This one stock-api | llmfit | claude-video | VideoCaptioner | claude-cookbooks | |
|---|---|---|---|---|---|
| Maker | zhangxiangliang | AlexsJones | bradautomates | WEIFENG2333 | anthropics |
| Skills | 1 | 1 | 1 | 1 | 4 |
| GitHub stars | 2,006 | 39,096 | 21,249 | 16,577 | 54,867 |
| Last code change | Nov 19, 2026 | Nov 18, 2026 | Sep 25, 2026 | Sep 12, 2026 | Nov 17, 2026 |
| License | MIT | MIT | MIT | GPL-3.0 | MIT |
1 skills (instruction sets) by zhangxiangliang that an AI reads and follows · not an MCP server
How a Skill differs from MCP
MCP = the hands
Connects the AI to an outside service or data, such as reading Notion or creating an invoice. A program or server has to be running.
Skill = the manual
A text file that teaches the AI how to do a task. It connects to nothing.
Some overlap: a few Skills run scripts that call tools, and a few MCP servers only send knowledge. Start from the task you want done.
Works with
Claude CodeCodex
From the maker’s README and the folders in the repo
Install
Is it safe?
- Who made it
GitHub account zhangxiangliang (person), 8 years old
- Use and upkeep
★ 2,006 stars · code last changed Nov 19, 2026
- Any scripts?
71 scripts that can run on a computer: eslint.config.mjs, jest.config.js, jest.integration.config.js, scripts/browser-smoke.mjs and 67 more
- Uses the internet?
Could not check every script (some are too large); read them first
- Changes machine-wide settings?
No hooks or writes to machine settings found
Checked automatically from the repo files at commit bdab240 (read only, nothing was run). Not a safety guarantee: read it and decide for yourself
First: which AI do you use?
Pick your app and this page shows only how to install it there
Option 1Upload to claude.ai (web and app)
Uploading to claude.ai would fail: the description is over 200 characters (258). Use "Let the AI install it" instead
Option 1Let Claude Code install it
Copy this sentence and paste it into a Claude Code chat
For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing
The AI tells you what it will do first and asks your permission at every step
Restart Claude Code, then type /stock-api or ask for a matching task and Claude picks it up
Checked against official docs Nov 12, 2026 · Source: code.claude.com
For Terminal users
A Skill is instructions the AI will follow. Read the files before installing, and install only from makers you trust.
Open Terminal
Mac: press Command+Space and type Terminal · Windows: the command below does not work in PowerShell; use “Let AI install it” above instead
Copy the skill folder to ~/.claude/skills
This downloads the repo to a temporary folder and copies only the folders that contain a SKILL.md
git clone --depth 1 https://github.com/zhangxiangliang/stock-api.git /tmp/popnx-skill-zhangxiangliang-stock-api-bdab240 && mkdir -p ~/.claude/skills && cp -R '/tmp/popnx-skill-zhangxiangliang-stock-api-bdab240/.' ~/.claude/skills/stock-apiRestart Claude Code, then type /stock-api or ask for a matching task and Claude picks it up
ChatGPT desktop app
The ChatGPT desktop app has Codex built in, and Codex reads skills from ~/.agents/skills
Option 1Let ChatGPT install it
Open Codex in the ChatGPT desktop app and paste this sentence into the chat
The AI always shows you the path before installing
The AI tells you what it will do first and asks your permission at every step
Option 2Put the folder there yourself
Put the stock-api folder at ~/.agents/skills/stock-api
~ is your home folder ($HOME)
For Terminal users
A Skill is instructions the AI will follow. Read the files before installing, and install only from makers you trust.
Open Terminal
Mac: press Command+Space and type Terminal · Windows: the command below does not work in PowerShell; use “Let AI install it” above instead
Copy the skill folder to ~/.agents/skills
This downloads the repo to a temporary folder and copies only the folders that contain a SKILL.md
git clone --depth 1 https://github.com/zhangxiangliang/stock-api.git /tmp/popnx-skill-zhangxiangliang-stock-api-bdab240 && mkdir -p ~/.agents/skills && cp -R '/tmp/popnx-skill-zhangxiangliang-stock-api-bdab240/.' ~/.agents/skills/stock-api
After installing
- ChatGPT desktop app: open Skills in the sidebar to see that the skill is there
- To use it: in ChatGPT type @ and pick the skill · in Codex CLI or the IDE extension run /skills or type $ and the skill name
- Codex picks up newly installed skills by itself; if one does not show up, restart Codex
Checked against official docs Nov 15, 2026 · Source: learn.chatgpt.com
ChatGPT on the web and mobile
Skills you install yourself do not work here; only skills that come with a plugin from the directory
To use this skill with ChatGPT, use the ChatGPT desktop app as above
Checked against official docs Nov 15, 2026 · Source: learn.chatgpt.com
Option 1Let Codex install it
Copy this sentence and paste it into a Codex chat · Works in Codex inside the ChatGPT desktop app, Codex CLI and the IDE extension
For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing
The AI tells you what it will do first and asks your permission at every step
Codex picks up newly installed skills by itself; if one does not show up, restart Codex · To use it: in ChatGPT type @ and pick the skill · in Codex CLI or the IDE extension run /skills or type $ and the skill name
Checked against official docs Nov 15, 2026 · Source: learn.chatgpt.com
For Terminal users
A Skill is instructions the AI will follow. Read the files before installing, and install only from makers you trust.
Open Terminal
Mac: press Command+Space and type Terminal · Windows: the command below does not work in PowerShell; use “Let AI install it” above instead
Copy the skill folder to ~/.agents/skills
This downloads the repo to a temporary folder and copies only the folders that contain a SKILL.md
git clone --depth 1 https://github.com/zhangxiangliang/stock-api.git /tmp/popnx-skill-zhangxiangliang-stock-api-bdab240 && mkdir -p ~/.agents/skills && cp -R '/tmp/popnx-skill-zhangxiangliang-stock-api-bdab240/.' ~/.agents/skills/stock-apiRestart Codex, then ask for a matching task; Codex lists the skill
Option 1Let Cursor install it
Copy this sentence and paste it into a Cursor chat
For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing
The AI tells you what it will do first and asks your permission at every step
In Cursor’s Agent chat, type / and pick stock-api
Checked against official docs Nov 12, 2026 · Source: cursor.com
For Terminal users
A Skill is instructions the AI will follow. Read the files before installing, and install only from makers you trust.
Open Terminal
Mac: press Command+Space and type Terminal · Windows: the command below does not work in PowerShell; use “Let AI install it” above instead
Copy the skill folder to ~/.cursor/skills
This downloads the repo to a temporary folder and copies only the folders that contain a SKILL.md
git clone --depth 1 https://github.com/zhangxiangliang/stock-api.git /tmp/popnx-skill-zhangxiangliang-stock-api-bdab240 && mkdir -p ~/.cursor/skills && cp -R '/tmp/popnx-skill-zhangxiangliang-stock-api-bdab240/.' ~/.cursor/skills/stock-apiIn Cursor’s Agent chat, type / and pick stock-api
Option 1Let the AI install it
For other apps that read skills. The sentence gives the paths for Claude Code, Codex and Cursor so the AI picks the one for your app · Copy this sentence into the app’s chat
For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing
The AI tells you what it will do first and asks your permission at every step
Checked against official docs Nov 12, 2026 · Source: code.claude.com, learn.chatgpt.com, cursor.com
For Terminal users
Other apps that support Agent Skills (such as Gemini CLI or GitHub Copilot) use different folders. Check that app’s guide, then copy the folder with the SKILL.md there.
Skill folders checked against the official Claude Code, Codex and Cursor guides on Nov 11, 2026
✓ Commands checked Nov 18, 2026
View the original SKILL.md
The text below comes from the maker’s repo, not from PopNx MCP
2,025 characters · Open the full file on GitHub
---
name: stock-api
description: Fetch real-time stock quotes, K-line (candlestick) history, and search symbols for China A-shares, Hong Kong, and US markets. Use when the user asks for a stock price, a quote, market data, candlestick/K-line data, or to look up a stock code by company name.
---
# stock-api
Get normalized stock market data by running the `stock-api` CLI. It covers
China A-shares, Hong Kong, and US markets, with automatic provider fallback
across Tencent, Sina, and Eastmoney.
## When to use
- The user wants a current price or quote for one or more stocks.
- The user wants K-line / candlestick history for charting or analysis.
- The user knows a company name but not its code (search first, then quote).
## How to run
Use `npx stock-api <command>`. Every command prints JSON to stdout.
Stock codes use a market prefix: `SH` / `SZ` (China), `HK` (Hong Kong),
`US` (US). Examples: `SH510500`, `SZ000651`, `HK02020`, `USDJI`.
### Get one quote
```bash
npx stock-api get-stock SH510500
```
### Get several quotes at once
```bash
npx stock-api get-stocks SH510500 SZ000651
```
### Get K-line (candlestick) history
```bash
npx stock-api get-klines SH600519 --period week --count 20
```
- `--period` — `day` (default), `week`, or `month`.
- `--count` — number of rows (defaults to the provider default).
- `--adjust` — `none` (default), `qfq` (forward), or `hfq` (backward).
### Search a code by keyword
```bash
npx stock-api search-stocks 格力电器
```
## Options (all commands)
- `--source` — `auto` (default), `tencent`, `sina`, or `eastmoney`.
Leave it on `auto` unless the user asks for a specific provider; `auto`
falls back across providers if one fails.
## Notes
- Output is JSON — parse it, don't reformat by hand, before showing the user.
- If a code returns no data, try `search-stocks` to confirm the correct code.
- For programmatic/persistent use, this same engine is also available as an
MCP server: `npx stock-api mcp`. Prefer the CLI commands above for one-off
lookups.
Discussion
Ask, share a tip or report that it does not work. Sorted by what people marked helpful.
No posts yet. Be the first to ask or share.
Posts here are written by users, not the PopNx team.
From GitHub
- GitHub stars
- 2,006
- Maker
- zhangxiangliang
- License
- MIT
- Last code change
- Nov 19, 2026
- SKILL.md files in the repo (including translated copies and templates)
- 1
- Topics
- browser, mcp, nodejs, stocks