返回顶部
c

cn-express-tracker

Query package tracking information from Chinese and international carriers using Kuaidi100 API. Supports auto-detection of carrier from tracking number. Use when user asks to track a package, check delivery status, query express/courier/logistics info, or mentions a tracking number. Triggers: 查快递, 快递查询, 物流查询, track package, tracking number, delivery status, 单号查询, express tracking, courier tracking.

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.0.0
安全检测
已通过
73
下载量
0
收藏
概述
安装方式
版本历史

cn-express-tracker

# Express Tracker(快递物流查询) Track packages from 200+ carriers (Chinese domestic + international) via Kuaidi100 API. ## Setup (Required) Users must obtain their own Kuaidi100 API credentials: 1. **Register** at [Kuaidi100 Open Platform](https://api.kuaidi100.com/register/enterprise) - 注册企业版账号(个人也可注册) - Free tier: 100 queries/day after verification 2. **Get credentials** from the [Kuaidi100 Dashboard](https://api.kuaidi100.com/home): - **授权 Key(API Key)**: Found in 授权信息 → 授权key - **Customer ID**: Found in 授权信息 → customer 3. **Set environment variables**: ```bash export EXPRESS_TRACKER_KEY="your_api_key_here" export EXPRESS_TRACKER_CUSTOMER="your_customer_id_here" ``` For persistent config, add to `~/.bashrc` or `~/.zshrc`: ```bash echo 'export EXPRESS_TRACKER_KEY="your_key"' >> ~/.zshrc echo 'export EXPRESS_TRACKER_CUSTOMER="your_customer"' >> ~/.zshrc ``` ## Usage ```bash # Auto-detect carrier and query scripts/track.sh <tracking_number> # Specify carrier manually scripts/track.sh <tracking_number> <carrier_code> ``` ### Examples ```bash # Auto-detect (recommended) scripts/track.sh 770308811947591 # Specify carrier explicitly scripts/track.sh SF1234567890 shunfeng ``` ## How It Works 1. **Carrier auto-detection**: Local rule-based matching by tracking number prefix/length/format 2. **API query**: Sends signed request to Kuaidi100 poll API with `resultv2=4` for advanced status 3. **Output**: Formatted timeline with full tracking history (newest first) ## Supported Carriers (Auto-Detection) | Prefix/Pattern | Carrier | Code | |---|---|---| | `SF` | 顺丰速运 | `shunfeng` | | `YT` | 圆通速递 | `yuantong` | | `JT` / `J0` | 极兔速递 | `jitu` | | `JD` | 京东快递 | `jd` | | `CN` | 菜鸟速递 | `cainiao` | | `DPK` | 德邦快递 | `debangkuaidi` | | `KYE` | 跨越速运 | `kuayue` | | `AN` | 安能物流 | `annengwuliu` | | `1Z` | UPS | `ups` | | `78/73/72/21/68` + digits | 中通快递 | `zhongtong` | | `10/11/12/13/19/46` + 13 digits | 韵达快递 | `yunda` | | `77/88/66/55/44` + 13-15 digits | 申通快递 | `shentong` | | `E` + letter + 9 digits + 2 letters | EMS | `ems` | If auto-detection fails, specify the carrier code manually as the second argument. Full carrier code list: [Kuaidi100 Carrier Codes](https://api.kuaidi100.com/manager/openapi/download/kdbm.do) ## Dependencies - `curl` — HTTP requests - `jq` — JSON parsing (install: `brew install jq` / `apt install jq`) - `openssl` or `md5sum` or `md5` — MD5 signature (at least one required) ## Error Codes | Code | Meaning | Action | |---|---|---| | 400 | Incomplete data / wrong carrier | Check carrier code | | 408 | Phone verification failed | SF/ZTO require phone number | | 500 | No tracking info found | Verify tracking number and carrier | | 503 | Signature verification failed | Check API Key and Customer ID | | 601 | API Key expired / no balance | Recharge account | ## Agent Integration When a user provides a tracking number, run: ```bash EXPRESS_TRACKER_KEY="$KEY" EXPRESS_TRACKER_CUSTOMER="$CUSTOMER" scripts/track.sh <number> ``` Parse the output and present the tracking timeline to the user. If carrier detection fails, ask the user which carrier it is.

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 cn-express-tracker-1776032644 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 cn-express-tracker-1776032644 技能

通过命令行安装

skillhub install cn-express-tracker-1776032644

下载 Zip 包

⬇ 下载 cn-express-tracker v1.0.0

文件大小: 6.16 KB | 发布时间: 2026-4-13 09:48

v1.0.0 最新 2026-4-13 09:48
- Initial release of cn-express-tracker for querying package tracking information via the Kuaidi100 API.
- Supports auto-detection of carrier from tracking number or manual carrier specification.
- Tracks packages from over 200 Chinese and international carriers.
- Requires user-provided Kuaidi100 API credentials (API Key and Customer ID) set via environment variables.
- Outputs detailed tracking timeline; provides error code explanations and manual carrier override options.
- Includes Bash script usage instructions and carrier code reference.

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部