v0.1.0
The first public release: weibo hot reads the Weibo trending board and delivers it as pipeable records.
The first public release. weibo is a single pure-Go binary that puts
Weibo's hot search board behind a command that feels like curl: fetch the
live trending list, shape it into clean records, and pipe it into the rest
of your tools. No API key, no login, nothing to run alongside it.
What you get
weibo hot. Fetches the Weibo hot search board (微博热搜榜) from
weibo.com/ajax/side/hotSearch and returns one HotItem per topic. Fields
include rank (1-based), word, scheme URL, heat score, category label, and
the topic search URL.
Output formats. Records render as table, JSON, JSONL, CSV, TSV, or URL list. The default is an aligned table on a terminal and JSONL when piped.
-n/--limit. Cap the number of results (default 30).
weibo version. Prints the version, commit, and build date.
Under the hood
- Desktop Chrome UA.
weibo.comrejects requests without a browser-like User-Agent. The client sends a Chrome 124 UA andReferer: https://weibo.com/. - Retry with backoff. On 429 or 5xx, the client backs off (500ms per attempt, capped at 5s) and retries up to three times.
- Rate pacing. A 500ms minimum gap between requests keeps the client polite against the public endpoint.
Install
go install github.com/tamnd/weibo-cli/cmd/weibo@latest
Prebuilt archives for Linux, macOS, and Windows, plus Linux packages (deb, rpm, apk) and checksums, are on the release page. The container image is on GHCR:
docker run --rm ghcr.io/tamnd/weibo:0.1.0 hot
The binary is pure Go with no runtime dependencies.