# 文章评论

按文章 URL 取评论。

ID: native-http:social.wechat.article.comments · Region: cn · Status: available

catalog_version: 5c920c774a55e44d7e8c709143b88a18b8b2afcef91a5d19a8c9ae5d565d9077
updated_at: 2026-10-21T12:06:16.523771+00:00

按文章 URL 取评论。

历史数据以数据集发布版本定义覆盖周期；实时读取反映请求时资料，不保证覆盖全部记录。

Docs: https://docs.asklear.cn/capabilities/native-http%3Asocial.wechat.article.comments

## POST /v1/native/social/wechat/articles/comments

native · available · api_key

REST 需要客户 API Key；MCP 需要已开放的服务及现有授权；CLI 需要已发布且包含该命令的客户端。

按文章 URL 取评论。

按成功请求计费，每次请求计一次；max_credits 限制本次费用上限。

恢复同一次原生请求时复用原 Idempotency-Key。

等待态响应提供结果/状态引用。先读取原结果；超时或结果不明时禁止自动重新提交付费执行。401/403/422 应先修正鉴权、权限或输入。

### Input schema / 输入契约

```json
{
  "$defs": {
    "Schema1": {}
  },
  "additionalProperties": false,
  "properties": {
    "input": {
      "additionalProperties": false,
      "properties": {
        "comment_id": {
          "anyOf": [
            {
              "maxLength": 32,
              "pattern": "^[0-9]*$",
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "description": "文章的评论 id（可选，**性能捷径**）：不传时上游要先抓并解析整篇文章 HTML 才能拿到它，约占本接口耗时的一半；已有该值时传进来可显著加快。取自 /fetch_article_detail 或 /fetch_article_detail_h5 响应的 `$.data.content.comment_id`/Article comment id (optional, performance shortcut): when omitted, upstream must fetch and parse the whole article HTML to obtain it, which accounts for about half of this endpoint's latency"
        },
        "cursor": {
          "default": "",
          "description": "翻页游标，首页留空；翻页传上一页响应的 buffer/Pagination cursor, leave empty for first page; pass buffer from the previous response",
          "maxLength": 8192,
          "pattern": "^[A-Za-z0-9+/=_-]*$",
          "type": "string"
        },
        "raw": {
          "default": false,
          "description": "True=原始响应；False=精简解析结构/True=raw response; False=simplified parsed structure",
          "type": "boolean"
        },
        "url": {
          "description": "公众号文章链接（https://mp.weixin.qq.com/s/…）/WeChat MP article URL (https://mp.weixin.qq.com/s/…)",
          "maxLength": 2048,
          "minLength": 1,
          "pattern": "^https?://mp\\.weixin\\.qq\\.com/s([/?].+)?$",
          "type": "string"
        }
      },
      "required": [
        "url"
      ],
      "type": "object"
    },
    "max_credits": {
      "anyOf": [
        {
          "maximum": 1000000000,
          "minimum": 0,
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null
    },
    "task_query": {
      "anyOf": [
        {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "description": "Optional task attribution: when provided, write one concise, self-contained task_query in the user's language and reuse that exact value in every call for the task, including discovery, search, approval retry, results, export, and status checks. For MCP calls, when omitted, Asklear records a generic non-user-specific attribution so compatible clients can still call the tool. REST calls may omit it and remain unattributed. It is a task description, not a task identifier. Do not include hidden reasoning, credentials, or direct personal identifiers such as phone numbers, email addresses, identity numbers, or street addresses.",
          "maxLength": 300
        },
        {
          "type": "null"
        }
      ],
      "default": null
    }
  },
  "required": [
    "input"
  ],
  "type": "object"
}
```

### Synthetic request / 合成请求

```json
{
  "input": {
    "url": "https://mp.weixin.qq.com/s/example"
  }
}
```

### Response schema / 响应契约

```json
{
  "$defs": {
    "Schema1": {},
    "Schema2": {
      "properties": {
        "api_name": {
          "type": "string"
        },
        "credits_charged": {
          "minimum": 0,
          "type": "integer"
        },
        "latency_ms": {
          "minimum": 0,
          "type": "integer"
        },
        "next_input": {
          "anyOf": [
            {
              "additionalProperties": false,
              "properties": {
                "comment_id": {
                  "anyOf": [
                    {
                      "maxLength": 32,
                      "pattern": "^[0-9]*$",
                      "type": "string"
                    },
                    {
                      "type": "null"
                    }
                  ],
                  "description": "文章的评论 id（可选，**性能捷径**）：不传时上游要先抓并解析整篇文章 HTML 才能拿到它，约占本接口耗时的一半；已有该值时传进来可显著加快。取自 /fetch_article_detail 或 /fetch_article_detail_h5 响应的 `$.data.content.comment_id`/Article comment id (optional, performance shortcut): when omitted, upstream must fetch and parse the whole article HTML to obtain it, which accounts for about half of this endpoint's latency"
                },
                "cursor": {
                  "default": "",
                  "maxLength": 8192,
                  "pattern": "^[A-Za-z0-9+/=_-]*$",
                  "type": "string"
                },
                "raw": {
                  "default": false,
                  "description": "True=原始响应；False=精简解析结构/True=raw response; False=simplified parsed structure",
                  "type": "boolean"
                },
                "url": {
                  "maxLength": 2048,
                  "minLength": 1,
                  "pattern": "^https?://mp\\.weixin\\.qq\\.com/s([/?].+)?$",
                  "type": "string"
                }
              },
              "required": [
                "url"
              ],
              "type": "object"
            },
            {
              "type": "null"
            }
          ]
        },
        "request_id": {
          "type": "string"
        }
      },
      "required": [
        "api_name",
        "request_id",
        "latency_ms",
        "credits_charged",
        "next_input"
      ],
      "type": "object"
    }
  },
  "properties": {
    "data": {
      "additionalProperties": true,
      "description": "Known optional fields from sanitized offline fixtures; conditional fields may be null. Additional business fields are retained.",
      "properties": {
        "code": {
          "type": [
            "integer",
            "null"
          ]
        },
        "data": {
          "additionalProperties": true,
          "properties": {
            "appmsgid": {
              "description": "Optional path documented by the source; presence depends on response mode and record type."
            },
            "buffer": {
              "description": "Optional path documented by the source; presence depends on response mode and record type."
            },
            "comment_id": {
              "description": "Optional path documented by the source; presence depends on response mode and record type."
            },
            "comments": {
              "items": {
                "additionalProperties": true,
                "properties": {
                  "content": {
                    "description": "Optional path documented by the source; presence depends on response mode and record type.",
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "content_id": {
                    "description": "Optional path documented by the source; presence depends on response mode and record type.",
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "create_time": {
                    "description": "Optional path documented by the source; presence depends on response mode and record type."
                  },
                  "id": {
                    "description": "Optional path documented by the source; presence depends on response mode and record type."
                  },
                  "ip_wording": {
                    "description": "Optional path documented by the source; presence depends on response mode and record type."
                  },
                  "is_elected": {
                    "description": "Optional path documented by the source; presence depends on response mode and record type."
                  },
                  "like_num": {
                    "description": "Optional path documented by the source; presence depends on response mode and record type."
                  },
                  "nick_name": {
                    "description": "Optional path documented by the source; presence depends on response mode and record type."
                  },
                  "replies": {
                    "items": {
                      "description": "Optional path documented by the source; presence depends on response mode and record type."
                    },
                    "type": [
                      "array",
                      "null"
                    ]
                  },
                  "reply_new": {
                    "description": "Optional path documented by the source; presence depends on response mode and record type."
                  },
                  "reply_total": {
                    "description": "Optional path documented by the source; presence depends on response mode and record type."
                  }
                },
                "type": [
                  "object",
                  "null"
                ]
              },
              "type": [
                "array",
                "null"
              ]
            },
            "content": {
              "additionalProperties": true,
              "properties": {
                "comment_id": {
                  "description": "Optional path documented by the source; presence depends on response mode and record type."
                }
              },
              "type": [
                "object",
                "null"
              ]
            },
            "elected_total": {
              "description": "Optional path documented by the source; presence depends on response mode and record type."
            },
            "has_more": {
              "description": "Optional path documented by the source; presence depends on response mode and record type.",
              "type": [
                "boolean",
                "null"
              ]
            },
            "total_count": {
              "description": "Optional path documented by the source; presence depends on response mode and record type."
            }
          },
          "type": [
            "object",
            "null"
          ]
        }
      },
      "type": "object"
    },
    "meta": {
      "$ref": "#/$defs/Schema2"
    }
  },
  "required": [
    "data",
    "meta"
  ],
  "type": "object"
}
```

### Synthetic response / 合成响应

```json
{
  "data": {
    "code": 200,
    "data": {
      "comments": [
        {
          "content": "评论",
          "content_id": "1001"
        }
      ],
      "has_more": false
    }
  },
  "meta": {
    "api_name": "social.wechat.article.comments",
    "credits_charged": 3,
    "latency_ms": 12,
    "next_input": null,
    "request_id": "asklear-example"
  }
}
```

- data (object): Known optional fields from sanitized offline fixtures; conditional fields may be null. Additional business fields are retained.
- data.code (integer|null): 暂无字段说明
- data.data (object|null): 暂无字段说明
- data.data.comments (array|null): 暂无字段说明
- data.data.has_more (boolean|null): Optional path documented by the source; presence depends on response mode and record type.
- data.data.content (object|null): 暂无字段说明
- data.data.content.comment_id (scalar): Optional path documented by the source; presence depends on response mode and record type.
- data.data.appmsgid (scalar): 文章消息 ID（如有）。
- data.data.elected_total (scalar): 精选总（如有）。
- data.data.total_count (scalar): 总数（如有）。
- data.data.buffer (scalar): Optional path documented by the source; presence depends on response mode and record type.
- data.data.comment_id (scalar): 评论 ID（如有）。
- meta (object): 暂无字段说明
- meta.api_name (string): 暂无字段说明
- meta.request_id (string): 暂无字段说明
- meta.latency_ms (integer): 暂无字段说明
- meta.credits_charged (integer): 暂无字段说明
- meta.next_input (scalar): 暂无字段说明
- data.data.comments[].content (string|null): 内容（如有）。
- data.data.comments[].content_id (string|null): 内容ID（如有）。
- data.data.comments[].nick_name (scalar): 昵称（如有）。
- data.data.comments[].like_num (scalar): 点赞数（如有）。
- data.data.comments[].create_time (scalar): 创建时间（如有）。
- data.data.comments[].ip_wording (scalar): 显示的 IP 属地（如有）。
- data.data.comments[].is_elected (scalar): 是否精选（如有）。
- data.data.comments[].reply_total (scalar): 回复总（如有）。
- data.data.comments[].replies (array|null): 暂无字段说明
- data.data.comments[].id (scalar): Optional path documented by the source; presence depends on response mode and record type.
- data.data.comments[].reply_new (scalar): Optional path documented by the source; presence depends on response mode and record type.
- meta.next_input.comment_id (string|null): 文章的评论 id（可选，**性能捷径**）：不传时上游要先抓并解析整篇文章 HTML 才能拿到它，约占本接口耗时的一半；已有该值时传进来可显著加快。取自 /fetch_article_detail 或 /fetch_article_detail_h5 响应的 `$.data.content.comment_id`/Article comment id (optional, performance shortcut): when omitted, upstream must fetch and parse the whole article HTML to obtain it, which accounts for about half of this endpoint's latency
- meta.next_input.cursor (string): 暂无字段说明
- meta.next_input.raw (boolean): True=原始响应；False=精简解析结构/True=raw response; False=simplified parsed structure
- meta.next_input.url (string): 暂无字段说明

Follow up: GET /v1/native/results/{query_id}
读取已保存结果，不重复查询数据或收费。

