# 微信公众号 文章传播数据 API (wechat_oa.article_metrics)

- Canonical page: [https://everyinfra.com/wechat-oa-api/article_metrics](https://everyinfra.com/wechat-oa-api/article_metrics?utm_medium=ai_doc&utm_campaign=page_md)
- Endpoint: POST https://api.everyinfra.com/api/v1/social with {"platform": "wechat_oa", "action": "article_metrics", "params": {...}}
- Price: $0.005556 per call ($5.56 per 1,000 requests); failed calls and empty results are not charged
- Returns: single object
- Mode: sync; add "mode": "async" for slow tasks

## Health

- Live health (24h percent, hourly and daily trends): https://api.everyinfra.com/api/v1/social/availability?platform=wechat_oa&action=article_metrics

## Parameters

| name | type | required | default | description |
|---|---|---|---|---|
| url | not declared | yes | not declared | article_comments / comment_replies / article_metrics / article_detail 使用 mp.weixin.qq.com 的文章自身链接（打开文章后复制：/s/<id> 短链，或带 __biz、mid、idx、sn 的链接）；从搜索结果复制的临时链接（带 signature/timestamp）可能读不了，读不了时扣费前返回 422。账号类接口仅把它作为公众号解析的最低优先级输入。 |

## Response fields (items in `results`)

| field | meaning |
|---|---|
| read_count | 阅读数。 |
| like_count | 点赞数。null 表示该平台或该接口不公开此数据，不等于 0。 |
| watching_count | 在看数。**公众号特有的互动指标，区别于点赞。** |
| share_count | 分享/转发数。null 表示不公开，不等于 0。 |
| collect_count | 收藏数。null 表示不公开，不等于 0。 |
| comment_count | 评论数。null 表示不公开，不等于 0。 |
| platform | 数据来源平台标识，与请求里的 platform 一致（如 xiaohongshu、tiktok）。 |

## Example

```bash
curl -X POST 'https://api.everyinfra.com/api/v1/social' \
  -H "Authorization: Bearer $EVERYINFRA_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "platform": "wechat_oa",
  "action": "article_metrics",
  "params": {
    "url": "https://mp.weixin.qq.com/s?__biz=MzA4MTg0MjA5OQ==&mid=2655362972&idx=1&sn=b56fabd8e4c53259498100f05f20dbb0"
  }
}'
```

```python
import os
import requests

response = requests.post(
    "https://api.everyinfra.com/api/v1/social",
    headers={"Authorization": f"Bearer {os.environ['EVERYINFRA_API_KEY']}"},
    json={
        "platform": "wechat_oa",
        "action": "article_metrics",
        "params": {
            "url": "https://mp.weixin.qq.com/s?__biz=MzA4MTg0MjA5OQ==&mid=2655362972&idx=1&sn=b56fabd8e4c53259498100f05f20dbb0",
        },
    },
    timeout=120,
)
print(response.status_code)
print(response.json())
```

## Response example

Real response to the example request above, captured 2026-10-24T18:28:34Z. `results` and `count` are real with personal information (names, handles, avatars, profile links, contact details) removed. `id`, `billing` and `quota` differ on every call, so only their shape is shown.

```text
{
  "id": "req_…",
  "platform": "wechat_oa",
  "action": "article_metrics",
  "results": {
    "read_count": 100001,
    "like_count": 1043,
    "watching_count": 122,
    "share_count": 3466,
    "collect_count": 358,
    "comment_count": 40,
    "platform": "wechat_oa"
  },
  "billing": {
    "charged": …,
    "charged_usd": …,
    "balance_after_usd": …,
    …
  },
  "quota": { … }
}
```

## Also

- Capability catalog (no key): https://api.everyinfra.com/api/v1/social/catalog?platform=wechat_oa
- OpenAPI: https://everyinfra.com/openapi.json · Agents guide: https://everyinfra.com/agents.md
