<p class="crumbs"><a href="/apis/">Data APIs</a> / <a href="/apis/xiaohongshu/">Xiaohongshu (RedNote)</a></p>

# PGY keyword daily index API

A keyword’s search index, notes, creators, impressions, reads and engagements for each day of about the last three months.

| Item | Value |
| --- | --- |
| Endpoint | `GET https://api.feedmcp.com/v1/xiaohongshu/pgy/keywords/history` |
| ID | `xiaohongshu.pgy.keywords.history` |
| Price | **$0.04** / call |
| Returns | A page of Stats objects |
| Auth | `Authorization: Bearer $FEEDMCP_API_KEY` |

## Parameters

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `keyword` | string | yes | Keyword |

Every endpoint also takes `view=full` to include the platform's raw data as `raw`, at the same price.

## Returned fields

`data.items` is a list of Stats objects, with the same fields on every platform:

| Field | Type | Description |
| --- | --- | --- |
| `platform` | string | Platform |
| `subject_id` | string | Whose figures these are: creator ID or keyword |
| `period` | string \| null | Period covered; for day-by-day lists, the day (YYYY-MM-DD) |
| `metrics` | object | The figures, named on each endpoint page; rates are 0–1 and money is CNY |

## When you are charged

$0.04 per call that returns data. Not found, no data, bad parameters, platform errors and timeouts are free.

Each answer carries `meta.billing`: what this call cost and the balance left.

## Request

### cURL

```bash
curl "https://api.feedmcp.com/v1/xiaohongshu/pgy/keywords/history?keyword=%E9%9C%B2%E8%90%A5" \
  -H "Authorization: Bearer $FEEDMCP_API_KEY"
```

### Python

```python
import os, requests

r = requests.get(
    "https://api.feedmcp.com/v1/xiaohongshu/pgy/keywords/history",
    params={"keyword": "露营"},
    headers={"Authorization": f"Bearer {os.environ['FEEDMCP_API_KEY']}"},
    timeout=30,
)
print(r.json())
```

### JavaScript

```js
const res = await fetch("https://api.feedmcp.com/v1/xiaohongshu/pgy/keywords/history?keyword=%E9%9C%B2%E8%90%A5", {
  headers: { Authorization: `Bearer ${process.env.FEEDMCP_API_KEY}` },
});
console.log(await res.json());
```

### MCP

From an AI with FeedMCP installed, the `call` tool:

```json
{
  "endpoint": "xiaohongshu.pgy.keywords.history",
  "params": {
    "keyword": "露营"
  },
  "max_price": "0.04"
}
```

## Response

The data below is made up; the shape is the real one.

```json
{
  "code": "ok",
  "request_id": "req_7Qm2kXb9TzLp",
  "data": {
    "items": [
      {
        "platform": "xiaohongshu",
        "subject_id": "露营",
        "period": "2026-08-21",
        "metrics": {
          "search_index": 10654,
          "notes": 35728,
          "creators": 27909,
          "impressions": 56022119,
          "reads": 7966451,
          "engagements": 329209
        }
      },
      {
        "platform": "xiaohongshu",
        "subject_id": "露营",
        "period": "2026-08-22",
        "metrics": {
          "search_index": 11133,
          "notes": 34585,
          "creators": 27020,
          "impressions": 52916422,
          "reads": 8209083,
          "engagements": 341413
        }
      }
    ]
  },
  "page": {
    "next_cursor": null,
    "has_more": false
  },
  "warnings": [],
  "meta": {
    "endpoint": "xiaohongshu.pgy.keywords.history",
    "platform": "xiaohongshu",
    "fetched_at": "2026-11-19T08:00:00.000Z",
    "source": "FeedMCP",
    "catalog_revision": "d09a736bd39e8b3f",
    "billing": {
      "charged": true,
      "amount": "0.04",
      "currency": "USD",
      "balance": "9.98"
    }
  }
}
```

Errors are described in [Errors](/docs/errors/): each says whether you were charged (`charged`) and whether to retry (`retry`).

## Other Xiaohongshu (RedNote) endpoints

- [Xiaohongshu note](/apis/xiaohongshu/notes/get/)：$0.02
- [Xiaohongshu note comments](/apis/xiaohongshu/notes/comments/list/)：$0.02
- [Xiaohongshu creator profile](/apis/xiaohongshu/users/get/)：$0.02
- [Xiaohongshu creator notes](/apis/xiaohongshu/users/notes/list/)：$0.02
- [Xiaohongshu note search](/apis/xiaohongshu/notes/search/)：$0.02
- [Xiaohongshu comment replies](/apis/xiaohongshu/notes/comments/replies/list/)：$0.02
- [Xiaohongshu account search](/apis/xiaohongshu/users/search/)：$0.02
- [PGY blogger search](/apis/xiaohongshu/pgy/creators/search/)：$0.04
- [PGY blogger profile](/apis/xiaohongshu/pgy/creators/get/)：$0.04
- [PGY blogger overview](/apis/xiaohongshu/pgy/creators/metrics/)：$0.04
- [PGY blogger note performance](/apis/xiaohongshu/pgy/creators/performance/)：$0.04
- [PGY blogger daily figures](/apis/xiaohongshu/pgy/creators/costs/history/)：$0.04
- [PGY blogger follower profile](/apis/xiaohongshu/pgy/creators/followers/get/)：$0.04
- [PGY blogger follower quality](/apis/xiaohongshu/pgy/creators/followers/metrics/)：$0.04
- [PGY blogger follower history](/apis/xiaohongshu/pgy/creators/followers/history/)：$0.04
- [PGY blogger notes](/apis/xiaohongshu/pgy/creators/notes/list/)：$0.04
- [PGY similar bloggers](/apis/xiaohongshu/pgy/creators/similar/list/)：$0.04
- [PGY note figures](/apis/xiaohongshu/pgy/notes/get/)：$0.04
- [PGY trending notes](/apis/xiaohongshu/pgy/notes/trending/)：$0.04
- [PGY keyword overview](/apis/xiaohongshu/pgy/keywords/metrics/)：$0.04
- [PGY related keywords](/apis/xiaohongshu/pgy/keywords/related/)：$0.04

## Questions

### How much does the PGY keyword daily index endpoint cost?

$0.04 per call that returns data. Not found, no data, bad parameters, platform errors and timeouts are free.

### Do I need a platform account?

No. Only public data is read.

### Where do I find the ID or link?

A note ID is the part after /explore/ in a note link; a share link (xhslink.com) works too.

### How do I get more items?

When the answer has `page.next_cursor`, pass it back as `cursor` for the next page. Each page is billed on its own.

### How do I use it from an AI?

Install the [MCP server](/mcp/) and ask; your AI calls `xiaohongshu.pgy.keywords.history`.

---

HTML version: https://feedmcp.com/apis/xiaohongshu/pgy/keywords/history/
