Xiaohongshu Details API
API health
- 24h health
- 95%
- 24h average time
- 2.58 s
- Healthy / normal
- Available
- Limited
- Mostly down
Last 24 hours
Last 30 days
Look up a Xiaohongshu account. Get nickname, Xiaohongshu ID, bio, IP location, verification and exact follower, following, post, like and save counts. Pass the ID from a /user/profile/ link, the link itself or a commenter's author_id. Counts that are not shown come back null, not zero.
Send POST https://api.everyinfra.com/api/v1/social with platform set to xiaohongshu and action set to profile. Price $5.56 per 1,000 requests ($0.005556 per call). Failed calls and empty results are not charged. Synchronous. For slow jobs add "mode": "async" to the body, take the job_id and poll.
Xiaohongshu Details reads one account's profile, given its user_id: nickname, Xiaohongshu ID, bio, avatar, gender, IP location, verification, follower and following counts, post count, and the likes and saves its notes have received. It tells brand teams, agencies and researchers how large and how engaged an account is before they shortlist a creator, sign a partnership or add the account to a tracking list.
Pass the ID that follows /user/profile/ in a profile link, the link itself, or a commenter's author ID from Xiaohongshu Comments results. follower_count is exact here, unlike the rounded figures in User search, and counts come back null rather than zero when they are not public. ip_location is the province or country the platform attaches to the account, not something the owner fills in, and real_name_info appears only when the profile shows real-name details.
AI prompt
#Please help me write a data collection script with the EveryInfra Xiaohongshu Details endpoint (xiaohongshu/profile).
How the endpoint works:
- Request: POST https://api.everyinfra.com/api/v1/social with the header Authorization: Bearer <API key>. Read the key from the EVERYINFRA_API_KEY environment variable and never hard-code it.
- In the request body, set platform to xiaohongshu and action to profile, and put the parameters inside params.
- Required parameters:
- user_id: Specifies the Xiaohongshu user ID (the identifier following /user/profile/ in the URL) or full profile URL for the profile and user_posts actions. The author_id returned by the comment actions also works.
- Returns one object. Main fields: user_id, nickname (Display name of the account), red_id (Xiaohongshu ID: the searchable ID the a…), url (The record's link on Xiaohongshu), bio, follower_count (Follower count), following_count, like_collect_count (The profile's likes-and-saves total: li…), post_count, gender (Gender as shown on the profile), ip_location (IP location (province or country) that…), avatar_url; 20 fields in total, full list at https://api.everyinfra.com/api/v1/social/catalog?platform=xiaohongshu.
- Example request body:
{
"platform": "xiaohongshu",
"action": "profile",
"params": {
"user_id": "5bec178863f51f0001859bd9"
}
}
- Price: $5.56 per 1,000 requests; failed and empty results are not charged.
- For dozens or hundreds of targets, add "mode": "async" to the body: you get a job_id at once and poll GET https://api.everyinfra.com/api/v1/jobs/{job_id} for the result.
- On 422, fix the request using the suggested parameter names and allowed values in the error; on 429 or 503, wait for Retry-After and try again.
Before writing code, ask me which targets I need, how many, which fields, and what output format I want; then confirm the plan and the rough cost with me.Request parameters
#| Name | In | Type | Required | Default | Description |
|---|---|---|---|---|---|
Authorization | header | string | Yes | - | Bearer followed by your API key. Create it in the console; never put it in a URL or a code repository. |
platform | body | string | Yes | xiaohongshu | Platform identifier, fixed value. |
action | body | string | Yes | profile | Capability identifier, fixed value. |
user_id | body.params | string | Yes | - | Specifies the Xiaohongshu user ID (the identifier following /user/profile/ in the URL) or full profile URL for the profile and user_posts actions. The author_id returned by the comment actions also works. Used to fetch profile details or published notes; does not accept username display names. |
Code samples
#curl -X POST 'https://api.everyinfra.com/api/v1/social' \
-H "Authorization: Bearer $EVERYINFRA_API_KEY" \
-H 'Content-Type: application/json' \
--data-raw '{
"platform": "xiaohongshu",
"action": "profile",
"params": {
"user_id": "5bec178863f51f0001859bd9"
}
}'OpenAPI definition (JSON)Samples read the key from the EVERYINFRA_API_KEY environment variable; copied code never contains your key.
Response example
#{ "id": "req_…", "platform": "xiaohongshu", "action": "profile", "results": { "user_id": "5bec178863f51f0001859bd9", "nickname": "•••", "red_id": "536248807", "url": "https://www.xiaohongshu.com/user/profile/5bec178863f51f0001859bd9?xsec_token=YBa43WesDF2ZG-HMGXVxTlt0t4eJdIhAYkDoVSOA1K-Ew%3D", "bio": "人生的觉醒消失于人群之中", "follower_count": 2114, "following_count": 49, "like_collect_count": 16889, "post_count": 752, "gender": 0, "ip_location": "•••", "avatar_url": "https://sns-avatar-qc-ae.rednotecdn.com/•••", "is_verified": false, "tags": [ "白羊座", "江苏扬州", "旅行博主" ], "like_count": 15178, "collect_count": 1711, "location": "中国 江苏 扬州", "platform": "xiaohongshu" }, "billing": { "charged": …, "charged_usd": …, "balance_after_usd": …, … }, "quota": { … }}
Response fields
#Business data is in results. The table lists the fields a record can contain; values the platform does not show are never made up.
| Field | Meaning |
|---|---|
user_id | User's unique ID on the platform. |
nickname | Display name of the account. |
red_id | Xiaohongshu ID: the searchable ID the account holder chooses, different from the internal user_id. |
url | The record's link on Xiaohongshu. Links from search, note, profile and hashtag usually carry an access token, so they open in a signed-out browser (the token expires; call again for a fresh link). Note links from user_posts carry no token and need one to open in a browser: call note with the note ID to get a link that opens. Profile links from search_users carry no token either; call profile with the user_id for one that opens. Note links from pgy_content_square carry a token, except with keyword, where they carry none. |
bio | Profile bio written by the account; may contain line breaks and emoji. |
follower_count | Follower count. Exact on profile. Approximate on search_users: the list shows a rounded figure (12,000 appears as 1.2 × 10,000), converted to a whole number. null means not public or not recognized, not zero. |
following_count | Accounts followed. null means not disclosed, not 0. |
like_collect_count | The profile's likes-and-saves total: likes received plus saves across the account's notes. like_count and collect_count give the two parts. |
post_count | Total posts. null means not disclosed, not 0. |
gender | Gender as shown on the profile; may be empty. |
ip_location | IP location (province or country) that Xiaohongshu displays; not entered by the user. Only some user_posts rows carry it. |
avatar_url | Avatar image link. Some platforms return sized CDN links that can expire. |
is_verified | Whether the platform verified the account. null means it cannot be determined. |
tags | Tag list: on note, the note's topic tags; on profile, the personal tags shown on the profile page (such as star sign or region); on reviews, the review tags the store attaches, such as good quality, absent when there are none. As written. |
like_count | Like count. On note and comment results, the likes on that item; on profile, the total likes the account's notes have received. null means not public or not returned this time, not zero. |
collect_count | Save count. On note results, how many times that note was saved; on profile, the total saves across the account's notes. null means not public or not returned this time, not zero. |
real_name_info | Real-name details exactly as the profile shows them; the field is absent when there are none. |
verification_type | Verification type on search_users and profile: individual (verified person), business (verified business) or other. Unverified accounts leave this field out. |
verification_text | Verification description as written on the profile (profile). |
location | Location description passed through as is; the format varies by platform. |
platform | Source platform identifier, the same as platform in the request (for example xiaohongshu, tiktok). |
FAQ
#What does like_collect_count measure?
#The likes-and-saves total shown on the profile: every like plus every save the account's notes have received. like_count and collect_count give the two parts separately, so you can see whether an audience mostly likes an account's notes or saves them to come back to.
Should I store user_id or red_id?
#Store both, but key your records on user_id, which is what you pass back to this capability and to Posts by user. red_id is chosen by the account holder and is what people type into the app's search, so it is handy for display and for matching an ID someone sends you.
Does the profile link open in a browser?
#Usually, yes. Links from this capability normally carry an access token, so they open without signing in until the token expires; calling again returns a fresh one. Profile links from User search and note links from Posts by user lack the token, which is why those capabilities point you here or to Note details.
Errors and billing
#- 401
- Missing or invalid key.
- 402
- Insufficient balance. Top up first.
- 422
- Invalid parameter name or value. Fix it using the suggestions in the error. No charge.
- 429
- Per-minute request limit reached. Wait for Retry-After, then try again.
- 503
- Could not complete. The held charge is returned to your balance. If the outcome is unknown, verify it before you retry.
- 200 empty
- No data. No charge.