Feature request: --sort option for rednote search (latest / popular)
- Dominant language
- JavaScript
- Stars
- 29.5k
- Forks
- 2.9k
- Avg merge
- 15h 36m
- Merged PRs (30d)
- 70
Description
## Feature request
Hi! Love the tool — it's been really useful for automating content discovery from Xiaohongshu.
### What I'd like
A `--sort` option for the `rednote search` command, mirroring the **综合** / **最新** tabs visible in the XHS search UI:
\`\`\`
opencli rednote search --sort latest
opencli rednote search --sort popular # current default behaviour
\`\`\`
### Why it matters
When searching by hashtag, the default relevance sort surfaces established high-engagement posts. New posts from smaller accounts — which are often more timely event announcements — don't appear in the first page of results even though they carry the hashtag.
Switching to **最新** sort in the XHS app surfaces those posts immediately. For any automation use case that needs fresh content (event discovery, news monitoring, etc.), this would be very valuable.
### What I think it involves
The XHS search page already renders a "最新" tab. I'd imagine it's a single click/navigation in the browser automation before results are collected — so hopefully a small change on your end.
Thanks for considering it!
Contributor guide
Research direction
Start at the `rednote search` command entry point and trace how it collects results from the XHS search page. Add the `--sort` handling for `latest` and `popular`, then verify that the selected sort matches the corresponding search UI tab and that the existing default behavior remains unchanged.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, playwright
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100