# 怎麼監控小紅書關鍵詞，每天拿到新發布的筆記？

> 監測小紅書上的品牌詞或產品詞：每天拉取最新筆記，只留過去 24 小時的，已經拿過的筆記不重複付費。

網頁版：https://okdata.online/zh-hant/answers/xiaohongshu-keyword-monitoring-new-notes/

**簡短回答：**每天用 okdata 按 sort=latest 搜一次關鍵詞，翻到比上次執行更早的筆記就停。大多數品牌詞一天只需要 1 到 3 頁，一個關鍵詞每天 $0.035 到 $0.105；10 個關鍵詞每天各翻 2 頁，一個月共 $21.00。

你想每天早上拿到一份清單，列出所有新發布的、提到自家品牌、競品或某個產品名的小紅書筆記，好讓社媒團隊中午前決定回覆、轉發還是上報。人工搜容易漏，App 裡的搜尋結果又把以前的熱門筆記和新筆記混在一起。每天按最新排序搜一次，翻到上次執行的位置就停，得到的就是這份清單。

## 做法

用[小紅書筆記搜尋](/zh/apis/xiaohongshu/notes/search/)，引數 `sort=latest`。結果從新到舊排列，每頁約 20 篇，每篇帶 `published_at`、標題、正文、圖片、作者和各項資料。

1. 每天跑一次搜尋（新品上市期間可以幾小時一次）。
2. 只保留 `published_at` 晚於上次執行時間的筆記。
3. 一旦某頁出現更早的筆記，或者出現已經存過的 ID，就停止翻頁。

介面沒有按日期篩選的引數，其實也用不著：按最新排序，再按時間截斷，得到的就是過去 24 小時的筆記。

## 費用

| 方案 | 每天呼叫 | 每天 | 30 天 |
|---|---|---|---|
| 1 個關鍵詞，通常 1 頁 | 1 | $0.035 | $1.05 |
| 10 個關鍵詞，各 2 頁 | 20 | $0.70 | $21.00 |
| 新品周：5 個關鍵詞每 4 小時一次 | 30 | $1.05 | — |

## 指令碼

```python
import os, requests, datetime as dt

URL = "https://api.okdata.online/v1/xiaohongshu/notes/search"
HEAD = {"Authorization": f"Bearer {os.environ['OKDATA_API_KEY']}"}
since = (dt.datetime.now(dt.timezone.utc) - dt.timedelta(days=1)).strftime("%Y-%m-%dT%H:%M:%S")
params, fresh = {"query": "某品牌 防曬", "sort": "latest"}, []

for _ in range(5):  # 翻頁上限
    body = requests.get(URL, headers=HEAD, params=params, timeout=60).json()
    items = body["data"]["items"]
    fresh += [n for n in items if n["published_at"] >= since]
    if not body["page"]["has_more"] or (items and items[-1]["published_at"] < since):
        break
    params["cursor"] = body["page"]["next_cursor"]
print(len(fresh), "new notes")
```

放進 cron，再把 `fresh` 推到群裡或者寫進表格。

## 心裡要有數的幾件事

- 小紅書搜尋是模糊匹配，品牌名太短會搜出不相關的筆記。加一個產品詞，或者在程式碼裡再按標題和正文過濾一遍。
- 搜尋結果裡有作者，但沒有作者粉絲數。想標出大號發的筆記，用[博主資訊](/zh/apis/xiaohongshu/users/get/)查一下作者。
- 每頁扣一次費，一頁裡沒有新筆記也照樣算一次呼叫。跑的頻率要和關鍵詞的熱度匹配。

## 其他選擇

輿情監測系統一般也覆蓋小紅書，帶看板和預警，適合完全不想寫程式碼的團隊。MediaCrawler 也能用登入帳號跑同樣的搜尋。要把評論和博主也納入監測，可以看[口碑監測方案](/zh/solutions/word-of-mouth/)。

## 用到的介面

- [小紅書筆記搜尋](https://okdata.online/zh/apis/xiaohongshu/notes/search/) `xiaohongshu.notes.search`：$0.035/次 · 每頁約 20 篇筆記
- [小紅書筆記詳情](https://okdata.online/zh/apis/xiaohongshu/notes/get/) `xiaohongshu.notes.get`：$0.035/次

## 更多小紅書內容

- [小紅書 API](https://okdata.online/zh/apis/xiaohongshu/)
- [小紅書 API Python 教程：筆記、博主和評論（2026）](https://okdata.online/zh/guides/xiaohongshu-api-python/)
- [怎麼按關鍵詞批次匯出小紅書評論](https://okdata.online/zh/guides/xiaohongshu-note-comments/)
- [怎麼在小紅書蒲公英按報價和閱讀量篩達人](https://okdata.online/zh/guides/xiaohongshu-pgy-creator-rates/)
- [怎麼搜尋小紅書筆記並匯出成 CSV 表格](https://okdata.online/zh/guides/xiaohongshu-search-export-notes/)
- [海外品牌怎麼監控小紅書上的品牌討論？](https://okdata.online/zh/answers/monitor-rednote-brand-mentions-outside-china/)
- [人在海外，怎麼讓 AI 讀到國內版小紅書的資料？](https://okdata.online/zh/answers/xiaohongshu-data-for-agents-outside-china/)
- [怎麼搭一個小紅書爆款筆記庫，用來找選題、拆爆文？](https://okdata.online/zh/answers/xiaohongshu-viral-notes-library/)
- [千問裡怎麼拿到抖音、小紅書、公眾號的資料？](https://okdata.online/zh/answers/qwen-douyin-xiaohongshu-data/)
- [騰訊元寶能讀抖音、小紅書的資料嗎？](https://okdata.online/zh/answers/yuanbao-douyin-xiaohongshu-data/)
- [小紅書返回 300011 帳號異常，怎麼繼續採集筆記？](https://okdata.online/zh/answers/xiaohongshu-300011-account-abnormal/)
- [自己爬還是按次呼叫資料介面：成本、維護和風險](https://okdata.online/zh/compare/scraping-vs-data-api/)
- [怎麼選社交媒體資料 API（2026）](https://okdata.online/zh/compare/social-media-data-apis/)
- [社媒資料 MCP 伺服器：自己部署還是用託管的](https://okdata.online/zh/compare/social-media-data-mcp-servers/)

## 資料來源

這個問題出現過的地方（讀取於 2026-11-17）：

- https://github.com/xpzouying/xiaohongshu-mcp/issues/214
- https://github.com/xpzouying/xiaohongshu-mcp/issues/661

更新於 2026-11-12
