Xiaohongshu Brand Monitoring: Pull Notes, Comments and Replies by API
Find the most-commented notes for a brand term, then read the note, its comments and threaded replies. Four calls, about $0.022, no login.
To watch what Xiaohongshu (RedNote) users say about a brand, run four calls per round: xiaohongshu/search finds the notes with the most comments for a brand term, xiaohongshu/note reads the text and engagement counts, xiaohongshu/comments pulls the comments, and xiaohongshu/sub_comments pulls the replies under one comment. Each costs $0.005556 at catalog price, so a round is about $0.022.
Every request and response below comes from live calls on November 29, 2026. The keyword in the requests is the Chinese name of Luckin Coffee, sent exactly as written.
| Step | Endpoint | Catalog price |
|---|---|---|
| 1 | xiaohongshu/search | $0.005556 |
| 2 | xiaohongshu/note | $0.005556 |
| 3 | xiaohongshu/comments | $0.005556 |
| 4 | xiaohongshu/sub_comments | $0.005556 |
Step 1: Find the most-commented notes for a brand term
Set sort to most_commented so notes with the most comments come first. The full call:
curl -X POST https://api.everyinfra.com/api/v1/social \
-H "Authorization: Bearer $EVERYINFRA_API_KEY" \
-H "Content-Type: application/json" \
-d '{"platform":"xiaohongshu","action":"search","params":{"keyword":"瑞幸咖啡","sort":"most_commented"}}'The request body on its own:
{
"platform": "xiaohongshu",
"action": "search",
"params": {
"keyword": "瑞幸咖啡",
"sort": "most_commented"
}
}Take the first result with a comment_count of at least 20 and keep its url exactly as returned. Steps 2 to 4 all use it, because it carries the xsec_token parameter they depend on.
{
"id": "6a44acf2000000000702fdc1",
"url": "https://www.xiaohongshu.com/explore/6a44acf2000000000702fdc1…",
"title": "第一个蛋终于孵化啦!",
"text": "#瑞幸咖啡联名多邻国",
"like_count": 17249,
"collect_count": 2189,
"comment_count": 3909,
"share_count": 14131,
"posted_at": "2026-07-01T06:00:18+00:00",
"is_video": true
}The response has a top-level next_page_token. Pass it back as page_token to get the next page; each page is one call.
Step 2: Read the note text and engagement counts
Read the note with the url from step 1 to get the text, hashtags and the poster's location. Replace the token placeholder in the request body with the original xsec_token value from that url.
{
"platform": "xiaohongshu",
"action": "note",
"params": {
"url": "https://www.xiaohongshu.com/explore/6a44acf2000000000702fdc1?xsec_token=<令牌>"
}
}This step feeds nothing to the next one. The url that note returns has no xsec_token, so keep using the link from step 1 for comments.
{
"id": "6a44acf2000000000702fdc1",
"title": "第一个蛋终于孵化啦!",
"text": "#瑞幸咖啡联名多邻国[话题]#",
"like_count": 17249,
"comment_count": 3909,
"share_count": 14131,
"posted_at": "2026-07-01T06:00:18+00:00",
"ip_location": "北京"
}Step 3: Pull the comments on the note
Same url again, this time for the first page of comments.
{
"platform": "xiaohongshu",
"action": "comments",
"params": {
"url": "https://www.xiaohongshu.com/explore/6a44acf2000000000702fdc1?xsec_token=<令牌>"
}
}Step 4 needs a comment id: pick one whose sub_comment_count is above 0. This first page returned 10 comments; page forward with next_page_token the same way.
{
"id": "6a44bd2c000000002100da78",
"text": "所有人跟我一起:啧。",
"like_count": 7742,
"sub_comment_count": 840,
"posted_at": "2026-07-01T07:09:33+00:00",
"author_name": "<昵称>",
"is_author": false
}Step 4: Pull the replies under one comment
Send the same url, plus the id of the comment from step 3 as comment_id.
{
"platform": "xiaohongshu",
"action": "sub_comments",
"params": {
"url": "https://www.xiaohongshu.com/explore/6a44acf2000000000702fdc1?xsec_token=<令牌>",
"comment_id": "6a44bd2c000000002100da78"
}
}Each reply's reply_to_id equals the comment id from step 3, so you can attach replies to their parent. When the top-level next_page_token has a value, pass it back as page_token for the next page.
{
"id": "6a44be80000000002300dec5",
"text": "羡慕的话不用说太多",
"like_count": 3431,
"posted_at": "2026-07-01T07:15:12+00:00",
"author_name": "<昵称>",
"reply_to_id": "6a44bd2c000000002100da78"
}What to do with the data
- Deduplicate comments and replies by
id. On a daily run, write only theidvalues that are new this time, and useposted_atfor ordering and daily trends. - Snapshot
like_count,comment_countandshare_countfor every note on every run. The difference between two snapshots is that day's growth, which spots a note that suddenly takes off sooner than totals would. - Fields worth storing: for notes,
id, the tokenizedurl,titleandip_location; for comments,id,text,like_count,sub_comment_countandposted_at; for replies, addreply_to_id.
Related pages
FAQ
How much does it cost to monitor a brand on Xiaohongshu every day?
Billing is per call, with prices in the capability catalog. These four steps cost $0.005556 each, about $0.022 a round. Each extra page of comments, or each extra comment whose replies you read, adds one call. One round a day on one note comes to about $0.67 a month.
Am I charged if a request fails or returns no data?
Failed requests, invalid parameters and bad keys are not charged. Most empty results are free too; the exceptions are listed in the catalog's field notes. For example, a note with no comments returns empty_reason set to no_comments and counts as one call.
Do I need a Xiaohongshu account, cookies or proxies?
No. Send your API key in an Authorization: Bearer header. There is no QR login or session to maintain, and no scraper, platform account or proxy to run yourself.
Can Claude or Cursor run this monitoring for me?
Yes. Add https://api.everyinfra.com/mcp to the client's remote MCP settings with an Authorization: Bearer header followed by your API key. The agent can then call all four capabilities through everyinfra_call_api, with the same parameters as the request bodies above.
Why do comments and replies need the link from the search results?
The url in search results carries xsec_token; the url returned by note does not. Use the full link from step 1 for both the comments and replies steps.
Reference UC-01