Install
openclaw skills install @zhouzidan/car-key查询车辆位置和车况信息(车锁、车门、车窗、空调等状态)/ Query vehicle location and condition information.
openclaw skills install @zhouzidan/car-key适用于已经加装 Tika 数字钥匙产品并完成 App 绑定的车辆。
Use this skill only after the vehicle has installed the Tika Digital Key product and completed App binding.
官网 / Official website: https://www.tikakey.com/
API Key 获取路径:乘趣 App -> 帮助中心 -> 热门功能 -> Skill。
API Key path: Chengqu App -> Help Center -> Popular Features -> Skill.
| 配置项 | 值 |
|---|---|
| API 地址 | https://openapi.nokeeu.com/iot/v1/condition |
| 缓存文件 | ~/.skill_carkey_cache.json |
| 认证格式 | App 生成的完整 API Key |
TIKA_API_KEY / Recommend TIKA_API_KEY as the primary setup method~/.skill_carkey_cache.json / If the user wants repeated local use, then save it to ~/.skill_carkey_cache.json--lang zh|en 切换 CLI 输出语言 / Support bilingual CLI output with --lang使用 Python 脚本查询车况信息:
Use the Python script to query vehicle information:
# 查询全部信息
python3 query_vehicle.py
# 使用单一环境变量直接查询
export TIKA_API_KEY='your_full_api_key'
python3 query_vehicle.py
python3 query_vehicle.py --check-auth
# 首次写入认证信息并查询
python3 query_vehicle.py --apikey 'your_full_api_key'
# 仅写入认证信息,不发起查询
python3 query_vehicle.py --apikey 'your_full_api_key' --save-token-only
# 检查当前认证状态
python3 query_vehicle.py --check-auth
# 删除本地认证缓存
python3 query_vehicle.py --clear-auth
# 仅查询车辆位置
python3 query_vehicle.py -p
python3 query_vehicle.py --position
# 仅查询车况信息
python3 query_vehicle.py -c
python3 query_vehicle.py --condition
# 输出原始 JSON 数据
python3 query_vehicle.py --json
python3 query_vehicle.py -p --json
python3 query_vehicle.py -c --json
# 使用英文输出
python3 query_vehicle.py --lang en
脚本文件:query_vehicle.py
| 字段路径 | 说明 |
|---|---|
data.sn | 数字钥匙 SN |
data.vin | 车架号 |
data.vehiclePosition.longitude/latitude | GPS 经纬度 |
data.vehiclePosition.address | 地址 |
data.vehiclePosition.positionUpdateTime | 位置更新时间戳(毫秒) |
data.vehicleCondition.power | 电源状态 |
data.vehicleCondition.gear | 档位 |
data.vehicleCondition.trunk | 后备箱状态 |
data.vehicleCondition.door.* | 车门状态 |
data.vehicleCondition.lock.* | 车锁状态 |
data.vehicleCondition.window.* | 车窗状态 |
data.vehicleCondition.airConditionerState.* | 空调温度设定 |
| 参数 | 简写 | 说明 |
|---|---|---|
--position | -p | 仅查询车辆位置信息 |
--condition | -c | 仅查询车况信息 |
--json | 输出纯 JSON 数据 | |
--apikey | 传入完整 API Key,并写入缓存 | |
--save-token-only | 仅保存 API Key 到缓存 | |
--check-auth | 仅检查缓存中的认证信息 | |
--clear-auth | 删除本地认证缓存 | |
--lang | 输出语言,支持 zh 和 en | |
| 无参数 | 查询全部信息 |
其他特性 / Additional notes:
TIKA_API_KEY / Support reading auth from environment variables, preferably TIKA_API_KEY| 错误类型 | 处理方式 |
|---|---|
| 认证信息缺失 | 引导用户提供完整 API Key |
| 认证格式错误 | 提示正确格式 |
| 缓存读写失败 | 返回明确文件错误 |
| API 请求失败 | 返回 HTTP 或接口错误信息 |
Python 3.6+