WeChat Get Article Stats
## Purpose Retrieve read and interaction counts for a WeChat Official Account article from its URL. ## Inputs - `request_body` (required): object containing the article URL and optional output preference. - `request_body.url` (required): WeChat MP article link on `mp.weixin.qq.com`, such as `https://mp.weixin.qq.com/s/TSNQKkRpN1qbKsT7BvzqIw`. Short links and long article links with `__biz` are supported when they match `^https?://mp\.weixin\.qq\.com/s([/?].+)?$`. Maximum length: 2048 characters. - `request_body.raw` (optional boolean; default `true`): use `false` for simplified counts or `true` for the full raw statistics object. ## Results Statistics are returned in `data`. With `raw=false`, the seven counters are: - `data.read_num`: reads. - `data.like_count`: likes. - `data.old_like_count`: Wow (在看) count. - `data.share_count`: shares. - `data.collect_count`: favorites. - `data.comment_count`: comments. - `data.star_num`: stars / likes. With `raw=true`, `data` includes the same counters plus visibility flags (`show_like`, `show_old_like`, `show_share`, `show_collect`, `show_read`, `show_star` and corresponding `*_gray` flags) and status fields (`comment_enabled`, `get_data_succ`, `is_subscribed`, `verify_status`, `can_use_star`). These fields describe visibility and status rather than additional engagement counts. The result is returned directly; no task polling is needed. Responses can be slow, so a 30-second client request timeout is recommended. This tool returns statistics, not article text or individual comments.
Pricing
| Condition | Charge |
|---|---|
| Each call | 20.65 credits/call |
Each call to retrieve WeChat Official Account article readership and interaction statistics has a fixed fee of 20.65 credits. Charges are per query. A successful query is billed even if it returns no results.
Parameters
Optional parameters use the platform defaults when omitted.
| Parameter | Type | Required | Description | Default |
|---|---|---|---|---|
request_body | object | Yes | 用于获取微信公众号文章互动统计的请求体对象。url 指定文章链接;可选 raw 控制返回模式,默认为 true:true 返回含显隐及状态标志的完整原始统计对象,false 仅返回精简计数。 | — |
request_body.raw | boolean | No | True=原始响应;False=精简解析结构/True=raw response; False=simplified parsed structure | true |
request_body.url | string | Yes | 公众号文章链接(https://mp.weixin.qq.com/s/… 或带 __biz 的长链)/WeChat MP article URL (https://mp.weixin.qq.com/s/… or long URL with __biz) | — |
Invocation example
Copy the request and explore its response example.
/agent-api/v1/tool/executeX-Api-Keycurl --request POST \
--url 'https://agentearth.ai/agent-api/v1/tool/execute?tool_name=ae_wechat_get_article_stats' \
--header "X-Api-Key: $AGENTEARTH_API_KEY" \
--header 'Content-Type: application/json' \
--data-raw '{
"params": {
"request_body": {
"raw": false,
"url": "http://mp.weixin.qq.com/s?__biz=Mzk2NDcxMjgyMg==&mid=2247625327&idx=1&sn=d3ac6befa5a65dbfcf6c0caece523f4c&chksm=c5f585e75f5c85e50b0687ea1e085ea28e4f22de751da46ee7b26b221407489c3b42d06d4a69&scene=126&sessionid=0#rd"
}
}
}'{
"code": 200,
"data": {
"collect_count": 0,
"comment_count": 0,
"debug_id": "8b1e9d4a",
"debug_info": "gAAAAABq7fpAe_hWepmuX03QbaR0dNlqMM2m5M_z1gDyiXBXMranVtMTTLDO9jjq7Ou04ZvW5DtBFRh9kjKzJ4C4kFcoD3DPFM1-b3ADd_3XEp5Vkp9Pj9hkSwl5_1yY5khNe46_JWuFS6DcDS8HgVrwItLNn88AFdpemh-6g3RP_Wdn6qlfCfDJ9DPi8yt_8rIHPUTFBq8h7Mb6t_ujtlD3RVtod1BHBKK-F2wyy245OUHqgymb8W9-cITY68HF",
"like_count": 4,
"old_like_count": 4
},
"docs": "https://api.tikhub.io/#/WeChat-Media-Platform-V2-API/fetch_article_stats_api_v1_wechat_mp_v2_fetch_article_stats_post",
"message": "Request successful. This request will incur a charge."
}This example shows part of the response. Copied content is valid JSON.


