V2EX API & Scraper
The V2EX API returns topics, replies, members and nodes from China's biggest developer community as clean JSON — no login, no token and no China exit required.
🤖 Using an AI assistant? Copy this link into ChatGPT / Claude / Cursor — it reads every endpoint and parameter instantly and tells you if this API fits your use case.
The primary search endpoint runs full-text search across V2EX topics and returns id, title, the full post body, url, the node it belongs to (id, name, Chinese and English titles), the author, reply_count, created_at and the matching snippets. You can also pull latest and hot topics, page one node with node_topics, expand a single topic with its reply thread, read a member profile with their user_topics, and browse the node taxonomy — the live nodes action reports 1,364 nodes. It suits developer-sentiment research, Chinese tech-market monitoring and training-set collection. One ReefAPI key, one shared credit pool, the standard envelope.
V2EX node slugs and their numeric ids
Almost every action here is scoped by a node, the sub-forum slug, and the search index stores nodes as bare numeric ids. These pairs are what you need to move between the two. Each row was read live on 2026-08-27 from the response that returned it.
| node slug | Title (Chinese / English) | node id | Measured on 2026-08-27 |
|---|---|---|---|
| qna | 问与答 / Questions and Answers | 12 | 241,092 topics, 4,511 subscribers, parent node v2ex |
| jobs | 酷工作 / Jobs | 43 | 60,700 topics, 6,539 subscribers, no parent node |
| programmer | 程序员 / Programmer | 300 | Read from the node block of topic 1236386 |
| all4all | 二手交易 / All for All | 69 | Read from the node block of a search hit |
| promotions | 推广 / Promotions | 864 | Read from the node block of a search hit |
The directory holds 1,364 nodes in total. nodes with a name returns exactly one for roughly 650 bytes; nodes with a query searches slug, Chinese title and English title together. Every timestamp comes back twice: created_at as Unix epoch seconds (1787750719) and created_at_iso as UTC (2026-08-26T13:25:19Z), same for last_touched_at and joined_at. meta.rate_limit passes V2EX's own budget straight through, with x-rate-limit-limit 600, the remaining count, and an epoch reset.
Real request and response JSON
Captured from the indexed primary action, search, on .
{
"method": "POST",
"url": "https://api.reefapi.com/v2ex/v1/search",
"headers": {
"x-api-key": "$REEF_KEY",
"content-type": "application/json"
},
"body": {
"q": "爬虫",
"limit": 10
}
}{
"ok": true,
"meta": {
"api": "v2ex",
"endpoint": "search",
"mode": "live",
"latency_ms": 2067.2,
"record_count": 10,
"bytes": 800072,
"cache_hit": false,
"method": "keyless_public_json_api_bare_dc_curl_cffi",
"stop_reason": "limit_reached",
"index": "sov2ex",
"match_is_loose_upstream": true,
"node_names_resolved": true
},
"data": {
"topics": [
{
"id": 1236386,
"source": "v2ex",
"title": "最近服务器负载一直下不来,经常到 100%,结果发现是各大 AI 厂商的机器人爬虫,疯狂请求我的网站",
"content": "从上周开始,我上线了一个小网站,需要一个关键字来搜索内容,结果被 chagptbot,claudebot,谷歌,还有 meta facebook 的这些机器人 疯狂提交参数,然后读取返回结果,我一直以为是中病毒了,结果今天一看网站日志,我去。\n\n全是 \n" Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; [redacted-email])"\nMozilla/5.0 (Linux; Android 6.0.1; Nexus 5X Build/MMB29P) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/[redacted-phone] Mobile Safari/537.36 (compatible; GoogleOther)"\n\n几乎达到了 攻击级别的访问。\n\n把我小站的流量 和 负载 干满了。\n\n在 nginx 里面加了一个\n\nif ($http_user_agent ~* \"(GPTBot|ChatGPT-User|ClaudeBot|anthropic-ai|PerplexityBot|Bytespider|GoogleOther|meta-externalagent|MJ12bot)\") {\n return 403;",
"url": "https://www.v2ex.com/t/1236386",
"node": {
"id": 300,
"name": "programmer",
"title": "程序员",
"title_en": "Programmer",
"url": "https://www.v2ex.com/go/programmer"
},
"author": {
"username": "qxmqh",
"url": "https://www.v2ex.com/u/qxmqh"
},
"reply_count": 1,
"created_at": 1787378570,
"created_at_iso": "[redacted-phone]T06:02:50Z",
"match_snippets": [
"最近服务器负载一直下不来,经常到 100%,结果发现是各大 AI 厂商的机器人爬虫,疯狂请求我的网站"
],
"score": null
},
{
"id": 1236352,
"source": "v2ex",
"title": "周末福利!动态住宅流量免费送,有需要的来领",
"content": "Zooproxy 全球 IP 代理,纯净长效稳定,跨境/采集/AI/codex 全场景覆盖,性价比超高\n🚀动态住宅流量:真实家庭宽带 IP ,按流量计费,不限 IP 数量,适配爬虫、AI 、数据采集、问卷调研等场景;\n🚀长效静态 ISP:固定住宅 IP ,按 IP 收费,不限流量,独享资源、稳定长在线,适配跨境店铺、社媒账号、企业应用托管等场景。\n\n✅ 全场景适配:电商监控 / 舆情分析 / 广告验证 / SEO 优化等 200 + 业务场景\n✅ 无缝集成:支持 Python/Java 等主流开发语言,提供 API 接口与 其他工具包\n✅ 7×24 小时技术支持:专属客户经理 1 对 1 服务,平均问题响应时间< 15 分钟\n\n🎁CDKey (领完可留言继续分享 )\nN88U-CV2C-V682\n5ZP4-DGTU-NT9F\nQ42H-DQDM-J72K\nC628-QT7G-T59V\nL5QV-2R85-WCLX\n点击进入个人中心 CDKey 区域兑换\nhttps://zooproxy.com/?kwd=zsy-v2ex",
"url": "https://www.v2ex.com/t/1236352",
"node": {
"id": 864,
"name": "promotions",
"title": "推广",
"title_en": "Promotions",
"url": "https://www.v2ex.com/go/promotions"
},
"author": {
"username": "0livia",
"url": "https://www.v2ex.com/u/0livia"
},
"reply_count": 0,
"created_at": 1787364733,
"created_at_iso": "[redacted-phone]T02:12:13Z",
"match_snippets": [
"费,不限 IP 数量,适配爬虫、AI 、数据采集、问卷调研等场景;\n🚀长效静态 ISP:固定住宅 IP ,按 IP 收费,不限流量,独享资源、稳定长在线,适配"
],
"score": null
},
{
"id": 1235642,
"source": "v2ex",
"title": "接单| AI 自动化代做(爬虫/脚本/Claude Code 工作流)",
"content": "能帮你做的:\n- 数据抓取:单站点/多站点爬虫,登录态、反爬、分页都能处理\n- 批量处理:Excel/CSV 清洗转换、文件批量重命名归档、报表自动生成\n- AI 工作流搭建:用 Claude Code 把你重复干的活(盯日志、写周报、跑测试、发通知)配成能自动跑的流程,不用你每次手动喊 AI\n\n技术栈:Python / Node.js / Claude Code / Claude Agent SDK\n\n报价按工作量来,简单脚本 300 起,工作流搭建面议。站内私信 or 评论区留需求,当天回复。",
"url": "https://www.v2ex.com/t/1235642",
"node": {
"id": 190,
"name": "outsourcing",
"title": "外包",
"title_en": "Outsourcing",
"url": "https://www.v2ex.com/go/outsourcing"
},
"author": {
"username": "yyfjj",
"url": "https://www.v2ex.com/u/yyfjj"
},
"reply_count": 0,
"created_at": 1787128746,
"created_at_iso": "[redacted-phone]T08:39:06Z",
"match_snippets": [
"接单| AI 自动化代做(爬虫/脚本/Claude Code 工作流)",
"能帮你做的:\n- 数据抓取:单站点/多站点爬虫,登录态、反爬、分页都能处理\n- 批量处理:Excel/CSV 清洗转换、文件批量重命名归档、报表自动生成"
],
"score": null
}
],
"total_matches_upstream": 12845,
"returned": 10,
"offset": 0,
"query": "爬虫",
"match": "any",
"source": "v2ex"
}
}What the V2EX API does
| Action | Description | Concrete use case | Key params |
|---|---|---|---|
| search | Full-text search across EVERY V2EX topic since 2010 (title + body + replies) — the historical archive the site's own JSON API does not expose. Filter by node, date range and sort by recency or relevance; each hit returns the full post body, author handle, node, reply count and markup-free match snippets. | Content platforms call search to get full-text search across EVERY V2EX topic since 2010 (title + body + replies). | q, match, sort, order, node, ... |
| node_topics | The newest topics of one V2EX node (sub-forum) with the COMPLETE post body — a live freshness feed for a niche: 'jobs' for hiring posts, 'outsourcing' for project leads, 'qna' for buying-intent questions, 'programmer' for developer chatter. Returns the node's own metadata (topic count, subscriber count) alongside. | Research tools call node_topics to get the newest topics of one V2EX node (sub-forum) with the COMPLETE post body. | node_name, limit |
| latest | The newest topics across the WHOLE of V2EX (all nodes), each with its full post body — a single-call firehose of what the Chinese dev community is posting right now (typically ~47 topics, the freshest usually minutes old). | Community analysts call latest to get the newest topics across the WHOLE of V2EX (all nodes), each with its full post body. | limit |
| hot | Today's most-discussed V2EX topics with full bodies — the site's own hot list, ordered by the traction the community itself gave them. | Media monitors call hot to get today's most-discussed V2EX topics with full bodies. | limit |
| topic | One V2EX topic by id or URL: the full post body plus the COMPLETE reply thread (every reply, in order, with author handle and timestamp) — the discussion is where the buying intent, the tool recommendations and the salary numbers actually live. | Content platforms call topic to get one V2EX topic by id or URL. | id, with_replies, replies_limit |
| user_topics | The newest topics posted by one V2EX member, with full bodies — follow a recruiter, a vendor or a prolific poster without watching every node. | Research tools call user_topics to get the newest topics posted by one V2EX member, with full bodies. | username, limit |
| member | Public profile of a V2EX member by handle or id: tagline, bio, website, github/twitter handle, self-typed location, join date and PRO status. Only what the member published themselves — the API exposes no e-mail, phone or real name. | Community analysts call member to get public profile of a V2EX member by handle or id. | username |
| nodes | The V2EX node taxonomy — all 1364 sub-forums with slug, Chinese and English title, topic count, subscriber count and parent node. Pass `name` for one node, or `query` to search the directory (matches slug, Chinese title and English title). This is how you find the `node_name` for `node_topics` and the `node` filter for `search`. | Media monitors call nodes to get the V2EX node taxonomy. | name, query, limit |
Call search from your stack
curl -X POST https://api.reefapi.com/v2ex/v1/search \
-H "x-api-key: $REEF_KEY" \
-H "content-type: application/json" \
-d '{"q":"爬虫","limit":10}'import requests
r = requests.post(
"https://api.reefapi.com/v2ex/v1/search",
headers={"x-api-key": REEF_KEY},
json={
"q": "爬虫",
"limit": 10
},
)
print(r.json()["data"])const res = await fetch("https://api.reefapi.com/v2ex/v1/search", {
method: "POST",
headers: {
"x-api-key": process.env.REEF_KEY,
"content-type": "application/json",
},
body: JSON.stringify({
"q": "爬虫",
"limit": 10
}),
});
const { ok, data, meta, error } = await res.json();Ask your MCP-connected assistant: call reefapi.v2ex.search with {"q":"爬虫","limit":10}.Who uses this API and why
- Developer-relations teams call search to find every V2EX thread discussing their product or a competitor.
- China-market researchers use node_topics on nodes like qna or programmer to track what local developers are asking about.
- Dataset builders use topic to pull a post body together with its complete reply thread as structured JSON.
- Community analysts use member and user_topics to profile an active contributor's posting history.
Questions developers ask before integrating
How do I find the right V2EX node slug?
Call nodes. Pass query to search the directory by slug, Chinese title or English title, or pass name to fetch exactly one node cheaply. The whole taxonomy is 1,364 nodes. The ones that carry commercial traffic are qna (问与答, node id 12, 241,092 topics measured 2026-08-27), jobs (酷工作, id 43, 60,700 topics), programmer (程序员, id 300) and outsourcing (外包). The slug is what node_topics and the search node filter both want.
Why did match=all return zero rows when the search reports thousands of matches?
Because the upstream index is loose and match=all is applied to the page you got back, not to the whole index. A live search for 树莓派 教程 with match all on 2026-08-27 returned total_matches_upstream 2,650, filtered_out 5 and returned 0: the index handed over five hits, none of which actually contained both tokens, and all five were dropped. The upstream total stays large because it counts loose matches. Raise limit so more rows survive the filter, or use the default match=any and score the results yourself.
How far back does the search go, and how deep can I page?
Every topic since 2010, title, body and replies. A live search for 爬虫 (web scraping) on 2026-08-27 reported total_matches_upstream 12,849. Paging is the real limit: the index refuses anything past offset + limit = 1000, so with limit 50 you can reach 20 pages and no further. Narrow with node, since and until rather than paging deeper.
Does the topic action return every reply?
It returns up to replies_limit, and it tells you when it stopped. A live read of topic 1236386 with replies_limit 2 came back with replies_returned 2, replies_total 8, replies_truncated true and replies_match_counter true. reply_count on the topic object is always the true total, so truncation is never silent. replies_limit goes up to 1,000.
Why does node_topics only ever return ten topics?
That is the node feed's own ceiling, and the response says so: meta.feed_cap 10 with meta.paginated false. The limit parameter is capped at 10 for the same reason. node_topics is a freshness feed, not an archive. For depth in one node, use search with the node filter, which reaches the full history.
Why does the author object differ between search and the other actions?
The search index and the site's own JSON API return different amounts of member data. A search hit's author carries only username and url. A node_topics, latest, hot or topic row carries id, username, url, tagline and avatar, and each reply also carries author_id alongside the nested author. If you need the numeric member id, take it from one of those actions or from member, not from a search hit.
Can last_touched_at be earlier than created_at?
Yes, and it was on a live read. Topic 1237466 in the jobs node returned created_at 1787750719 (2026-08-26T13:25:19Z) with last_touched_at 1787750659 (2026-08-26T13:24:19Z), sixty seconds earlier. V2EX sets the two from different clocks on the posting path, so do not assume last_touched_at is greater than or equal to created_at and do not compute a duration from the pair.
Does the response tell me how much V2EX quota is left?
It does. meta.rate_limit on node_topics, topic, member and nodes passes V2EX's own headers straight through: x-rate-limit-limit 600, x-rate-limit-remaining, and x-rate-limit-reset as an epoch second. That budget is the site's, counted per hour, and it is separate from your ReefAPI credits. The search action goes through a different index and does not report it.
What is the V2EX API?
V2EX API is a ReefAPI endpoint group for topics, replies, members and nodes from china's biggest developer community. It returns live JSON through POST requests under /v2ex/v1.
Is the V2EX API free to try?
Yes. ReefAPI starts with 1,000 free credits, no card required. V2EX calls use the same shared credit balance as every other ReefAPI engine.
Do I need a V2EX login or account?
No login to V2EX is needed for the API response. You call ReefAPI with your x-api-key header, and the playground can run live examples before you create a production key.
How fresh is the V2EX data?
The page example is captured from a live search call, and production requests fetch live data through ReefAPI rather than a static sample.
How many credits does the V2EX API use?
V2EX actions currently cost 1 credit per successful call. Failed or blocked calls are free, and all APIs draw from one credit pool.
Can I call V2EX from an AI assistant or MCP client?
Yes. Connect ReefAPI once through MCP and your assistant can call v2ex actions with the same key, credit pool and JSON envelope used by normal REST requests.