Xiaohongshu (RedNote) PGY related keywords API

Get what people search on Xiaohongshu before and after a keyword, from the platform's creator marketplace, each with its place by relevance, its search index, the notes about it and their reads: for expanding a seed keyword. The search index is the platform's index, not a count of searches; for a word the platform gives no figures for, these are null. About 98 items a call, 120 at most; $0.0400 per call. Errors and timeouts are not charged; an empty result is charged $0.0400.

GEThttps://api.dataxapi.com/v1/xiaohongshu/pgy/keywords/related
Also known asxiaohongshu related searchesrednote keyword expansionxhs upstream downstream keywordsIn Chinese: 小红书蒲公英关联词 API
Price$0.0400/ call · Errors and timeouts are not charged
Returnsup to 120 a pageeverything in one answer, no paging
When an upstream failsRetried for youon the same route, or a backup route; never charged

Try it

Change a value and the request on the right follows.
Run · $0.0400

Sign in to run it; it runs on your own balance. New accounts can try this endpoint free, up to 2 calls.

The first 5 rows of a response recorded 2026-10-12 21:42 UTC for 烧烤.
FieldValue
keyword烧烤
related_to露营
relationprior
rank1
search_index2,638,774
curl -G "https://api.dataxapi.com/v1/xiaohongshu/pgy/keywords/related" \
  --data-urlencode "keyword=面膜" \
  -H "Authorization: Bearer $DATAXAPI_API_KEY"
{
  "code": "ok",
  "request_id": "14b8ced1-2b33-47f6-90f7-86463f68684e",
  "data": {
    "items": [
      {
        "keyword": "烧烤",
        "related_to": "露营",
        "relation": "prior",
        "rank": 1,
        "search_index": 2638774
      },
      // … 97 more
    ]
  },
  "page": {
    "next_cursor": null,
    "cursor_expires_at": null,
    "has_more": false,
    "returned": 98
  },
  "warnings": [],
  "meta": {
    "capability": "xiaohongshu.pgy.keywords.related",
    "result_status": "complete",
    "fetched_at": "2026-10-12T21:42:15.000Z",
    "cached": false,
    "replayed": false,
    "unavailable": {
      "relevance": "platform",
      "composite_index": "platform"
    },
    "billing": {
      "amount": "0.04",
      "currency": "USD",
      "balance_after": "9.96"
    }
  }
}

From a response recorded 2026-10-12 21:42 UTC. Names, text and IDs are examples, and so are the links: none is the recorded one (the page shows no one's personal data); the figures are as recorded. Long lists are cut. The request ID, cursor and balance are made up.

Size as sent: 9.8 KB in the standard view (9.8 KB compact, 13.6 KB full).

{
  "code": "ok",
  "request_id": "be0abe47-fa2e-4d8d-81ca-6c0b66d1346b",
  "data": { "items": [] },
  "page": {
    "next_cursor": null,
    "cursor_expires_at": null,
    "has_more": false,
    "returned": 0
  },
  "warnings": [],
  "meta": {
    "capability": "xiaohongshu.pgy.keywords.related",
    "result_status": "empty",
    "fetched_at": "2026-10-12T21:59:51.000Z",
    "cached": false,
    "replayed": false,
    "unavailable": {
      "relevance": "platform",
      "composite_index": "platform"
    },
    "billing": {
      "amount": "0.04",
      "currency": "USD",
      "balance_after": "9.96"
    }
  }
}

From a response recorded 2026-10-12 21:59 UTC. The request ID and balance are made up.

Size as sent: 466 B in the standard view (466 B compact, 466 B full).

This example as a JSON file

curl -G "https://api.dataxapi.com/v1/xiaohongshu/pgy/keywords/related" \
  --data-urlencode "keyword=面膜" \
  -H "Authorization: Bearer $DATAXAPI_API_KEY"
from dataxapi import DataXAPI

dx = DataXAPI()  # reads DATAXAPI_API_KEY
result = dx.xiaohongshu.pgy.keywords.related(keyword="面膜")
print(result["data"]["items"])
import { DataXAPI } from "@dataxapi/sdk";

const dx = new DataXAPI(); // reads DATAXAPI_API_KEY
const result = await dx.xiaohongshu.pgy.keywords.related({ keyword: "面膜" });
console.log(result.data.items);
dataxapi call xiaohongshu.pgy.keywords.related 'keyword=面膜'
{
  "mcpServers": {
    "dataxapi": {
      "type": "http",
      "url": "https://api.dataxapi.com/mcp",
      "headers": {
        "Authorization": "Bearer ${DATAXAPI_API_KEY}"
      }
    }
  }
}

Add this to your MCP client, then ask your agent to call xiaohongshu.pgy.keywords.related.

Parameters

keywordtextrequired

One keyword. Example: 面膜.

viewtext

How much of each item to return. All three cost the same. Values: compact, standard (default), full.

fieldslist of text

Return only these fields. Each by its path, such as author.name.

Known limits

Returned fields

data.items is a list of related keyword objects. Preview: the structure may change, announced beforehand.

keywordtextcompact

The related keyword

related_totextcompact

The keyword it is related to: the one asked about

relationtextcompact

How it is related: query (searched together with the keyword asked about), posts (appears together with it in content), prior (searched before it), after (searched after it)querypostspriorafter

rankintegercompact

Position by relevance among the keywords of the same relation, from 1

relevancenumbercompactThe platform has none

How closely it is related to the keyword asked about, 0 to 1

search_indexintegercompact

Search index of the related keyword: the platform's index, not a count of searches; null where the platform gives no figure for the word

Show all 12 fields →
composite_indexintegercompactThe platform has none

Composite index of the related keyword: the platform's index of how much attention content about it drew, not a count

ext.notesintegerfull

Notes about the related keyword; null where the platform gives no figure for the word

ext.viewsintegerfull

Reads of those notes in all; null where the platform gives no figure for the word

approximatelist of objectcompact

Which numbers of this item are approximate or lower bounds; absent when all are exact

approximate[].fieldtextcompact

Path of the field, such as metrics.views

approximate[].kindtextcompact

Approximate, or a lower boundapproximatelower_bound

Typical size of one item: compact 98 B, standard 98 B, full 137 B (measured on the response recorded 2026-10-12 21:42 UTC).

What this endpoint cannot give

relevanceThe platform has none
composite_indexThe platform has none

When you are charged

A result with data$0.0400, once per call
An empty result$0.0400
Invalid parameters, a failure of ours or of the data source, a timeoutnot charged
CaseCharged
The most one call can cost$0.0400 (send X-Max-Price to refuse anything above your own limit)

Prices as read 2026-10-21 09:10 UTC, under price book 2, in effect since 2026-10-17 11:00 UTC; the Playground reads the price in force before a run.

If the object does not exist

A keyword the platform has no data for reads like one with no related keywords: an empty result, never a not-found error.

Errors

What this endpoint can answer with; codes all endpoints share are on the full list.

HTTPCodeMeaningCharged
400invalid_paramsA parameter is invalidRetry: After a fixNo
402insufficient_balanceThe balance is too lowRetry: After a fixNo
502upstream_failedThe data source failedRetry: YesNo
504timeoutThe data did not arrive in time; retry with the same idempotency keyRetry: YesNo

All error codes →

Questions

How much does the Xiaohongshu (RedNote) PGY related keywords API cost?

$0.0400 per call. The most one call can cost is $0.0400.

When am I not charged?

Errors and timeouts are not charged; an empty result is charged $0.0400.

How many items does one call return, and how do I get the next page?

About 98 items a page, 120 at most. The page size is the platform's; limit is not accepted. Everything comes in one page; no cursor is issued.

What happens if the object does not exist?

A keyword the platform has no data for reads like one with no related keywords: an empty result, never a not-found error.

All 21 Xiaohongshu (RedNote) endpoints

Xiaohongshu PGY endpoints
Xiaohongshu (RedNote) endpoints
Xiaohongshu Shop endpoints

Use it in your AI

Copy this prompt

Your API key is built in, so there is nothing to configure.

Read https://dataxapi.com/agents.md and set up DataXAPI in this agent. My API key is dx_…; use it for every DataXAPI call.
Sign in to copy it with your key

No account yet? Sign-up takes an email and no card, and a failed call is never charged.

then paste

Paste it into your agent

It reads the page the prompt points to and connects itself.

Your agent
Read https://dataxapi.com/agents.md and set up DataXAPI in this agent. My API key is dx_••••; use it for every DataXAPI call.
DataXAPI connected · 5 tools ready
now try it

Now ask something

Use one of these, or your own words.

Read https://dataxapi.com/apis/xiaohongshu/pgy/keywords/related.md and help me use the DataXAPI endpoint xiaohongshu.pgy.keywords.related (Xiaohongshu (RedNote) PGY related keywords).
Prefer to set it up by hand?
dataxapi setupgives the agents on your machine (Claude Code, Codex, Cursor) the DataXAPI MCP server and the base skill. The key is read from DATAXAPI_API_KEY; none is written into a file.MCP server: https://api.dataxapi.com/mcp. The entry for your client is under MCP in the request examples of this page; then ask your agent to call xiaohongshu.pgy.keywords.related.Other clients →
Ask with this pageSends the Markdown version
Brief for an AIEverything needed to call it, as text
Show the text
Use the DataXAPI endpoint xiaohongshu.pgy.keywords.related (Xiaohongshu (RedNote) PGY related keywords). Get what people search on Xiaohongshu before and after a keyword, from the platform's creator marketplace, each with its place by relevance, its search index, the notes about it and their reads: for expanding a seed keyword. The search index is the platform's index, not a count of searches; for a word the platform gives no figures for, these are null.
Call GET https://api.dataxapi.com/v1/xiaohongshu/pgy/keywords/related with the header "Authorization: Bearer $DATAXAPI_API_KEY". Read the key from the environment variable DATAXAPI_API_KEY; never write it into code.
Parameters:
- keyword (required): One keyword. Example: 面膜.
- view: How much of each item to return. All three cost the same. Values: compact, standard (default), full.
- fields: Return only these fields. Each by its path, such as author.name.
Price: $0.0400 per call. Errors and timeouts are not charged; an empty result is charged $0.0400.
The answer is JSON: data.items holds related keyword; meta.billing.amount is what this call was charged.
Example:
curl -G "https://api.dataxapi.com/v1/xiaohongshu/pgy/keywords/related" \
  --data-urlencode "keyword=面膜" \
  -H "Authorization: Bearer $DATAXAPI_API_KEY"
Full reference in Markdown: https://dataxapi.com/apis/xiaohongshu/pgy/keywords/related.md

Names and identifiers

In Chinese
小红书蒲公英关联词 API
Endpoint ID
xiaohongshu.pgy.keywords.related
Endpoint
GET /v1/xiaohongshu/pgy/keywords/related
Last checked 2026-10-21 09:10 UTC.View the Markdown versionopenapi.jsonllms.txt

Start with one key.

207 endpoints on 21 platforms, from $0.0003 a call. Errors and timeouts are not charged.

Start free