CLI for China Bird Record (birdreport.cn); default API host weixin.birdrecord.cn.
Project description
[!CAUTION]
⚠️ 声明(非官方)!!!
本项目并非 中国观鸟记录中心 的官方项目,与其无隶属或授权关系。仅供个人研究使用,禁止滥用。 数据解释权归中国观鸟记录中心所有。
This repository is not an official project of 中国观鸟记录中心. Personal research only; misuse is prohibited. Interpretation of data belongs to 中国观鸟记录中心.
Birdrecord CLI
Command-line tool for 观鸟记录 / China Bird Record data, plus Agent Skills for the same workflows in agents. Look up species on the center checklist, search and summarize observation records (regions, dates, species, chart-style filters), and fetch one record’s full detail by id.
Species taxonomy: Checklist entries, names, and taxonid values match the app and follow Zheng 4—the 4th edition of A Checklist of the Birds of China (中国鸟类分类与分布名录·第四版, “郑四”).
[!TIP]
OpenClaw — TL;DR (Agent Skills)
Paste the block below into OpenClaw.
Install the Agent Skills from https://github.com/yoshino-s/birdrecord-cli (under skills/) for OpenClaw. Run: npx skills add https://github.com/yoshino-s/birdrecord-cli -a openclaw -y from a suitable directory, then npx skills list to verify. If global install fits my machine better, use -g and say why.
Install from PyPI
Requires Python 3.12+.
pip install birdrecord-cli
# or: uv tool install birdrecord-cli
birdrecord-cli --help
Package index: pypi.org/project/birdrecord-cli.
Run with uvx (no prior install)
uv downloads the package into an ephemeral environment. Pin the version for reproducible behavior:
uvx --from 'birdrecord-cli==0.1.2' birdrecord-cli --help
uvx --from 'birdrecord-cli==0.1.2' birdrecord-cli provinces --pretty
Use the latest release version from PyPI if it differs from the example above.
Usage
Shared flags: --token, --base-url, --no-verify, --timeout, --pretty, --envelope. Subcommands: provinces, cities, taxon, report, search; most support --schema. search accepts optional --taxon / --report for activity drill-down; stdout JSON shapes are described in docs/CLI.md under search output (JSON). Full copied --help text: docs/CLI.md.
birdrecord-cli provinces --pretty
birdrecord-cli report --id 1948816 --pretty
birdrecord-cli search --body-json '{"startTime":"2026-02-24","endTime":"2026-03-24","province":"河北省","taxonid":4148,"version":"CH4"}' --pretty
Environment variables:
BIRDRECORD_CACHE_DIR: optional taxon cache root (…/taxon); if unset,$XDG_CACHE_HOME/birdrecord/taxonwhenXDG_CACHE_HOMEis set, else~/.cache/birdrecord/taxon.BIRDRECORD_CLI_CN: any truthy value (not0/false/no/off) uses Chinese JSON Schema descriptions (e.g.--schema).
Agent skills (npx skills)
The repo includes Agent Skills under skills/ (birdrecord-search, birdrecord-report-detail, birdrecord-taxon-search) so agents like Cursor know how to call birdrecord-cli safely. OpenClaw: use the highlighted tip box above Install from PyPI. Manual install with the skills CLI (Cursor: Skills):
# Install all skills (CLI detects agents; interactive prompts)
npx skills add yoshino-s/birdrecord-cli
# Preview what would be installed
npx skills add yoshino-s/birdrecord-cli --list
# Cursor only, skip prompts (CI / scripts)
npx skills add yoshino-s/birdrecord-cli -a cursor -y
# One skill only
npx skills add yoshino-s/birdrecord-cli --skill birdrecord-search -a cursor -y
For a fork, use owner/repo instead of yoshino-s/birdrecord-cli, or a direct tree URL, e.g. https://github.com/yoshino-s/birdrecord-cli/tree/main/skills/birdrecord-search.
Demo
Development
Clone, then uv sync --group dev && uv run pytest tests/ -v (some tests hit the live API; some use verify=False). Library code lives under birdrecord_cli/. Run the CLI from a dev tree with uv run birdrecord-cli ….
License
MIT — see LICENSE.
Contact
中文说明:README.zh-CN.md
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file birdrecord_cli-0.1.2.tar.gz.
File metadata
- Download URL: birdrecord_cli-0.1.2.tar.gz
- Upload date:
- Size: 33.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ffba4318b8403d5bf5d65a95098ab9a2619f3652befd125d4a97380d66cd8343
|
|
| MD5 |
ac873a84deb961f5a1334a8d34ea69fc
|
|
| BLAKE2b-256 |
35a5b689840e286247c0d3500eebfa101896836a7a19f7c30b22e984611e37d0
|
Provenance
The following attestation bundles were made for birdrecord_cli-0.1.2.tar.gz:
Publisher:
release.yml on yoshino-s/birdrecord-cli
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
birdrecord_cli-0.1.2.tar.gz -
Subject digest:
ffba4318b8403d5bf5d65a95098ab9a2619f3652befd125d4a97380d66cd8343 - Sigstore transparency entry: 1293493427
- Sigstore integration time:
-
Permalink:
yoshino-s/birdrecord-cli@3b240c3bfcce0f30977e2ad2531694dbcd00bb79 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/yoshino-s
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@3b240c3bfcce0f30977e2ad2531694dbcd00bb79 -
Trigger Event:
push
-
Statement type:
File details
Details for the file birdrecord_cli-0.1.2-py3-none-any.whl.
File metadata
- Download URL: birdrecord_cli-0.1.2-py3-none-any.whl
- Upload date:
- Size: 40.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4bf7b093dec11e4b76f3bc01a5f1f5693ffc8987447f379332852cd2bb96c0c6
|
|
| MD5 |
599b6067b616ba987dd994d4bf1d55f4
|
|
| BLAKE2b-256 |
4d42f3b32c75d587a82c5b18291c76f60c6787e170afcba2eb5eefa3185b521e
|
Provenance
The following attestation bundles were made for birdrecord_cli-0.1.2-py3-none-any.whl:
Publisher:
release.yml on yoshino-s/birdrecord-cli
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
birdrecord_cli-0.1.2-py3-none-any.whl -
Subject digest:
4bf7b093dec11e4b76f3bc01a5f1f5693ffc8987447f379332852cd2bb96c0c6 - Sigstore transparency entry: 1293493473
- Sigstore integration time:
-
Permalink:
yoshino-s/birdrecord-cli@3b240c3bfcce0f30977e2ad2531694dbcd00bb79 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/yoshino-s
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@3b240c3bfcce0f30977e2ad2531694dbcd00bb79 -
Trigger Event:
push
-
Statement type: