# Why can't ChatGPT or Claude open a Xiaohongshu link?

> Xiaohongshu puts login walls and bot checks in front of its pages, so AI browsing sees nothing. Hand the assistant a note's text, images and comments by link.

Canonical page: https://okdata.online/answers/ai-cant-open-xiaohongshu-link/

**Short answer: **Xiaohongshu puts login prompts and bot checks in front of its web pages and draws notes with JavaScript, so AI browsing usually gets a login wall or an empty page. Give the assistant a tool that takes the link instead: Xiaohongshu note detail returns the full text, image links, likes, saves and comment count for $0.02, and comments cost $0.02 per page.

An agency sends you 15 Xiaohongshu links from a rival's campaign. You paste them into ChatGPT or Claude and ask which ones got the most saves and why. The answer is an apology, or a confident summary of a login page. Nothing is wrong with the assistant: its browser arrives without a Xiaohongshu session, gets a login prompt or a bot check, and the note itself is built by scripts it never runs. The way around it is to hand the assistant a tool that fetches the note by link and returns data instead of a web page.

## Link in, note out

[Xiaohongshu note detail](/apis/xiaohongshu/notes/get/) takes the link exactly as you copied it, including xhslink.com share links from the app. It returns the full text, every image URL (or the video), likes, saves, comment count, hashtags and the author. [Xiaohongshu note comments](/apis/xiaohongshu/notes/comments/list/) then takes the note's ID from that answer and returns about 10 comments per page, each with likes and reply count.

If you use Claude Code, Claude Desktop or Cursor, connect the [MCP server](/mcp/) and paste links as before; the assistant calls note detail on its own. In a script it looks like this:

```python
import os
import requests

API = "https://api.okdata.online"
H = {"Authorization": f"Bearer {os.environ['OKDATA_API_KEY']}"}

def get(path, **params):
    body = requests.get(API + path, headers=H, params=params, timeout=60).json()
    if body["code"] != "ok":
        raise RuntimeError(f"{body['code']}: {body['message']}")
    return body

note = get("/v1/xiaohongshu/notes/get", url="https://xhslink.com/a/xxxxxxx")["data"]["item"]
print(note["title"], note["metrics"]["likes"], note["metrics"]["favorites"])

comments, cursor = [], None
for _ in range(2):
    extra = {"cursor": cursor} if cursor else {}
    body = get("/v1/xiaohongshu/notes/comments/list", id=note["id"], fields="text,likes,replies", **extra)
    comments += body["data"]["items"]
    if not body["page"]["has_more"]:
        break
    cursor = body["page"]["next_cursor"]
```

## What it costs

| Task | Calls | Cost |
|---|---|---|
| One note | 1 | $0.02 |
| One note plus 2 pages of comments | 3 | $0.06 |
| The 15 campaign notes, text only | 15 | $0.30 |
| 15 notes plus 2 comment pages each | 45 | $0.90 |

Notes that were deleted or made private return `not_found` and are not charged.

## Gotchas

- Many notes carry their message in image cards. The API returns image URLs, not the words inside them; pass those URLs to a vision model if the text in the pictures matters.
- Xiaohongshu does not show view counts, so views are always empty. Saves and likes are the better signal.
- Comment pages are small, about 10 each, so a note with 800 comments takes dozens of calls. Cap the pages.
- Only public notes. Comments are written by strangers; ask the assistant to treat them as data.

## When something else is better

For one to three notes, screenshots pasted into ChatGPT or Claude work well, and vision models read the text on image cards nicely. Copying the caption by hand is free. If you also want to post or reply as yourself, a local Xiaohongshu MCP server logged into your own account does that, at the price of scanning a QR code when the session expires. For regular research across many notes, see [content research](/solutions/content-research/).

## Endpoints used

- [Xiaohongshu note detail](https://okdata.online/apis/xiaohongshu/notes/get/) `xiaohongshu.notes.get`: $0.02 per call
- [Xiaohongshu note comments](https://okdata.online/apis/xiaohongshu/notes/comments/list/) `xiaohongshu.notes.comments.list`: $0.02 per call · about 10 comments per page

Updated 2026-11-12
