pp-tesla
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chinese<!-- GENERATED FILE — DO NOT EDIT.
This file is a verbatim mirror of library/devices/tesla/SKILL.md,
regenerated post-merge by tools/generate-skills/. Hand-edits here are
silently overwritten on the next regen. Edit the library/ source instead.
See AGENTS.md "Generated artifacts: registry.json, cli-skills/". -->
<!-- GENERATED FILE — DO NOT EDIT.
This file is a verbatim mirror of library/devices/tesla/SKILL.md,
regenerated post-merge by tools/generate-skills/. Hand-edits here are
silently overwritten on the next regen. Edit the library/ source instead.
See AGENTS.md "Generated artifacts: registry.json, cli-skills/". -->
Tesla — Printing Press CLI
Tesla — Printing Press CLI
Prerequisites: Install the CLI
前置条件:安装CLI
This skill drives the binary. You must verify the CLI is installed before invoking any command from this skill. If it is missing, install it first:
tesla-pp-cli- Install via the Printing Press installer:
bash
npx -y @mvanhorn/printing-press install tesla --cli-only - Verify:
tesla-pp-cli --version - Ensure (or
$GOPATH/bin) is on$HOME/go/bin.$PATH
If the install fails before this CLI has a public-library category, install Node or use the category-specific Go fallback after publish.
npxIf reports "command not found" after install, the install step did not put the binary on . Do not proceed with skill commands until verification succeeds.
--version$PATHThe Tesla owner-API as JSON-first commands, with a local SQLite that remembers every vehicle state. Get a single yes/no for departure, a tariff-aware charging cost ledger that replaces TeslaMate's Docker stack, and a supercharger queue watcher you can subscribe to from an agent. For 2018+ Models S/X and pre-2021 Models 3/Y, commands route end-to-end on plain REST; newer vehicles get a clear shim message via .
readytesla reachability此技能基于二进制文件运行。在调用此技能的任何命令之前,你必须确认CLI已安装。如果未安装,请先执行以下步骤:
tesla-pp-cli- 通过Printing Press安装程序安装:
bash
npx -y @mvanhorn/printing-press install tesla --cli-only - 验证安装:
tesla-pp-cli --version - 确保(或
$GOPATH/bin)已添加到$HOME/go/bin环境变量中。$PATH
如果在该CLI进入公共库分类前安装失败,请安装Node.js,或在发布后使用特定分类的Go备用安装方式。
npx如果安装后执行提示“command not found”,说明安装步骤未将二进制文件添加到。在验证成功前,请不要执行技能命令。
--version$PATHTesla车主API以JSON优先命令形式提供,搭配本地SQLite数据库记录所有车辆状态。你可以获取车辆是否适合出发的单一是/否结果、替代TeslaMate Docker栈的费率感知型充电成本台账,以及可由Agent订阅的超级充电桩队列监控功能。对于2018年后的Model S/X车型和2021年前的Model 3/Y车型,命令通过纯REST实现端到端路由;较新车型则通过传递清晰的垫片消息。
readytesla reachabilityWhen to Use This CLI
何时使用此CLI
Use tesla-pp-cli when you want a JSON-first CLI for your Tesla owner account: vehicle state inspection, climate/lock/charge commands, charging cost analytics, and an MCP surface for AI agents to drive your car. Faster than the iOS app for one-off commands, more agent-friendly than TeslaPy, and ships a local SQLite that delivers TeslaMate-style analytics (drives, charges, vampire drain, cost ledger) without standing up Postgres+Grafana. Best fit for owners with pre-2021 Models S/X or 3/Y on the old REST endpoints; newer vehicles get a clear shim via .
tesla reachability当你需要一个面向Tesla车主账户的JSON优先CLI时,可使用tesla-pp-cli:车辆状态检查、空调/锁车/充电命令、充电成本分析,以及供AI Agent控制车辆的MCP接口。它比iOS应用执行单次命令更快,比TeslaPy更适合Agent集成,并且自带本地SQLite数据库,无需部署Postgres+Grafana即可提供TeslaMate风格的分析功能(行驶、充电、电量损耗、成本台账)。最适合拥有2021年前Model S/X或3/Y车型且使用旧版REST端点的车主;较新车型可通过使用清晰的垫片层。
tesla reachabilityUnique Capabilities
独特功能
These capabilities aren't available in any other tool for this API.
这些功能是其他同类型API工具所不具备的。
Composite truth from local state
基于本地状态的综合判断
-
— Single yes/no answer to "can I leave in 5 minutes?" with reasoned blocker list - SOC vs trip distance, plugged-in, doors closed, sentry off, cabin within 3F of target, no mid-install update
readyMost-asked Tesla owner question; the iOS app makes it a 6-tap diagnostic, agents need a one-call truthbashtesla ready 5YJ3E1EA6XXXXXXXX --json
-
— 针对“我能在5分钟内出发吗?”给出单一的是/否答案,并列出合理的阻碍因素——电池电量与行程距离对比、是否插电、车门是否关闭、哨兵模式是否关闭、车内温度与目标温度差是否在3华氏度以内、是否正在安装更新
ready这是Tesla车主最常问的问题;iOS应用需要点击6次才能完成诊断,而Agent只需一次调用即可获取结果bashtesla ready 5YJ3E1EA6XXXXXXXX --json
Local analytics that beat the dashboard
超越官方仪表盘的本地分析
-
— Per-session cost, monthly spend, home-vs-Supercharger ratio with tariff-window aware $/kWh
cost ledgerCharging cost is the #1 Tesla-owner spreadsheet exercise; this is the first pure-CLI replacement for the TeslaMate dashboardbashtesla cost ledger --since 2026-04-01 --group supercharger --json -
— "If you had only charged at home you would have saved $X over the last 90 days." Re-runs charge rows with home $/kWh substituted for Supercharger sessions
cost what-ifMost Tesla owners suspect they could save by charging at home but lack proof; this puts a dollar figure on itbashtesla cost what-if --only-home --since 90d --json -
— Stitched drives + charges from synced vehicle_states polls - start/end, distance, energy, efficiency, address-resolved lat/lng
timelineLets agents reason over the same data TeslaMate exposes, without standing up Docker+Postgres+Grafanabashtesla timeline --since "last week" --json -
— SOC delta vs idle time, flags suspicious sentry sessions or app-wake events
vampireWarranty-dispute evidence and rogue-sentry detection; TeslaMate dashboard only otherwisebashtesla vampire --threshold 1.5pct/24h --since 30d --json
-
— 按会话统计成本、月度支出、家用充电与超级充电桩充电的占比,同时考虑费率时段的$/kWh计算
cost ledger充电成本是Tesla车主最常使用电子表格记录的内容;这是首个纯CLI替代TeslaMate仪表盘的工具bashtesla cost ledger --since 2026-04-01 --group supercharger --json -
— “如果仅在家充电,过去90天你本可以节省$X。”该功能会将超级充电桩充电会话的费用替换为家用$/kWh重新计算
cost what-if大多数Tesla车主怀疑在家充电能省钱,但缺乏证据;此功能可给出具体的金额数据bashtesla cost what-if --only-home --since 90d --json -
— 由同步的vehicle_states轮询数据拼接而成的行驶+充电时间线——起止时间、行驶距离、能耗、能效、地址解析后的经纬度
timeline让Agent可以处理TeslaMate暴露的相同数据,无需部署Docker+Postgres+Grafanabashtesla timeline --since "last week" --json -
— 电池电量变化与闲置时间对比,标记可疑的哨兵模式会话或应用唤醒事件
vampire可作为保修纠纷证据和异常哨兵模式检测工具;除此之外只有TeslaMate仪表盘具备此功能bashtesla vampire --threshold 1.5pct/24h --since 30d --json
Charging intelligence nobody else exposes
独家充电智能功能
-
— Single-poll snapshot of free stalls at a saved Supercharger; --watch repeats every N seconds with JSON-lines transitions
supercharger watchAvoids the I-90 Issaquah queue at peak; pageable from an agent on a drivebashtesla supercharger watch 1000 --free-stalls 2 --watch --json
-
— 已保存的超级充电桩站点的空闲车位单次轮询快照;
supercharger watch参数可每隔N秒重复轮询并输出JSON格式的状态变化--watch可避开高峰时段的I-90伊萨夸充电桩队列;Agent可在行驶过程中分页查看bashtesla supercharger watch 1000 --free-stalls 2 --watch --json
Security audit nobody else does
独家安全审计功能
-
— Lists every enrolled key with last-seen, role, form-factor; flags keys not seen >90d as stale candidates for removal
keys auditSecurity-minded owners worry about old phones and abandoned NFC cards still pairing with their car; this is the quarterly reviewbashtesla keys audit --stale-after 90d --json
-
— 列出所有已注册的钥匙及其最后使用时间、权限、形态;标记超过90天未使用的钥匙作为待移除的过期候选
keys audit注重安全的车主担心旧手机和废弃的NFC卡仍与车辆配对;此功能可用于季度安全检查bashtesla keys audit --stale-after 90d --json
Reachability mitigation
可达性缓解工具
-
— Detects signed-command-required errors, classifies the vehicle as REST-friendly vs signed-command-required, prints tesla-control enrollment URL when needed
doctorTesla's 2024-2026 signed-command rollout is the #1 user-facing landmine for any Tesla CLI; this is the only one that surfaces it clearlybashtesla doctor --json
-
— 检测需要签名命令的错误,将车辆分类为支持REST或需要签名命令的类型,必要时打印tesla-control注册URL
doctorTesla在2024-2026年推出的签名命令是所有Tesla CLI面临的最大用户障碍;这是唯一能清晰展示此问题的工具bashtesla doctor --json
Discovery Signals
发现信号
This CLI was generated with browser-observed traffic context.
- Capture coverage: 58 API entries from 60 total network entries
- Protocols: firebase (75% confidence), rest_json (75% confidence)
- Auth signals: bearer_token — headers: authorization; cookie — cookies: _abck, bm_sz; api_key — query: key
- Generation hints: browser_clearance_required, requires_browser_auth
- Candidate command ideas: create_auto_conditioning_start — Derived from observed POST /api/{id}/vehicles/5YJ3E1EA6XXXXXXXX/command/auto_conditioning_start traffic.; create_auto_conditioning_stop — Derived from observed POST /api/{id}/vehicles/5YJ3E1EA6XXXXXXXX/command/auto_conditioning_stop traffic.; create_diagnostic — Derived from observed POST /mobile-app/macgyver/diagnostic traffic.; create_door_lock — Derived from observed POST /api/{id}/vehicles/5YJ3E1EA6XXXXXXXX/command/door_lock traffic.; create_door_unlock — Derived from observed POST /api/{id}/vehicles/5YJ3E1EA6XXXXXXXX/command/door_unlock traffic.; create_fireperf:fetch — Derived from observed POST /v1/projects/tesla-prod/namespaces/fireperf:fetch traffic.; create_hermes — Derived from observed POST /api/{id}/vehicles/5YJ3E1EA6XXXXXXXX/jwt/hermes traffic.; create_keys — Derived from observed POST /api/{id}/users/keys traffic.
此CLI是基于浏览器捕获的流量上下文生成的。
- 捕获覆盖范围:60个网络条目里的58个API条目
- 协议:firebase(75%置信度)、rest_json(75%置信度)
- 认证信号:bearer_token — 请求头:authorization;cookie — Cookie:_abck, bm_sz;api_key — 查询参数:key
- 生成提示:browser_clearance_required、requires_browser_auth
- 候选命令灵感:create_auto_conditioning_start — 基于观测到的POST /api/{id}/vehicles/5YJ3E1EA6XXXXXXXX/command/auto_conditioning_start流量推导;create_auto_conditioning_stop — 基于观测到的POST /api/{id}/vehicles/5YJ3E1EA6XXXXXXXX/command/auto_conditioning_stop流量推导;create_diagnostic — 基于观测到的POST /mobile-app/macgyver/diagnostic流量推导;create_door_lock — 基于观测到的POST /api/{id}/vehicles/5YJ3E1EA6XXXXXXXX/command/door_lock流量推导;create_door_unlock — 基于观测到的POST /api/{id}/vehicles/5YJ3E1EA6XXXXXXXX/command/door_unlock流量推导;create_fireperf:fetch — 基于观测到的POST /v1/projects/tesla-prod/namespaces/fireperf:fetch流量推导;create_hermes — 基于观测到的POST /api/{id}/vehicles/5YJ3E1EA6XXXXXXXX/jwt/hermes流量推导;create_keys — 基于观测到的POST /api/{id}/users/keys流量推导。
Command Reference
命令参考
charging — Supercharger queue position and charging status
- — Current Supercharger queue position (which stall, ETA)
tesla-pp-cli charging
diagnostics — Vehicle diagnostic feature config
- — Vehicle diagnostic feature flags
tesla-pp-cli diagnostics
energy_sites — Powerwall and solar energy site config
- — Set Powerwall backup reserve percent
tesla-pp-cli energy_sites create-set-backup-reserve - — Set Powerwall operation mode
tesla-pp-cli energy_sites create-set-operation - — Historical energy data per day/month
tesla-pp-cli energy_sites get-calendar-history - — Real-time Powerwall solar/grid/battery power
tesla-pp-cli energy_sites get-live-status - — Utility rate plans for Powerwall scheduling
tesla-pp-cli energy_sites get-rate-tariffs - — Energy site config (capacity, type, address)
tesla-pp-cli energy_sites get-site-info - — Backup-reserve and operation mode
tesla-pp-cli energy_sites get-site-status
logs — Client-side telemetry sink
- — Forward client-side log events (mostly internal use)
tesla-pp-cli logs
notification_preferences — Push notification settings
- — Update push notification preferences
tesla-pp-cli notification_preferences
products — Vehicles, Powerwalls, and solar products owned by the user
- — List vehicles, Powerwalls, and solar products owned
tesla-pp-cli products
users — Account config, feature flags, orders, and key/credential management
- — Add a virtual phone key or BLE key
tesla-pp-cli users create-keys - — Mobile app feature flags and runtime config
tesla-pp-cli users get-app-config - — Account-level feature gating
tesla-pp-cli users get-feature-config - — Tesla orders (new vehicle deliveries, accessory purchases)
tesla-pp-cli users get-orders
vehicles — Per-vehicle data, climate, locks, remote start, and Hermes telemetry token
- — Open/close trunk or frunk; which_trunk = front | rear
tesla-pp-cli vehicles create-actuate-trunk - — Add a charging schedule (location + time window)
tesla-pp-cli vehicles create-add-charge-schedule - — Add a preconditioning schedule
tesla-pp-cli vehicles create-add-precondition-schedule - — Set volume to specific level
tesla-pp-cli vehicles create-adjust-volume - — POST /api/1/vehicles/{vehicle_id}/command/auto_conditioning_start
tesla-pp-cli vehicles create-auto-conditioning-start - — POST /api/1/vehicles/{vehicle_id}/command/auto_conditioning_stop
tesla-pp-cli vehicles create-auto-conditioning-stop - — Toggle bioweapon defense mode (HEPA recirculation)
tesla-pp-cli vehicles create-bioweapon-mode - — Cancel pending software update
tesla-pp-cli vehicles create-cancel-software-update - — Set charge limit to Max Range (100%)
tesla-pp-cli vehicles create-charge-max-range - — Close the charge port
tesla-pp-cli vehicles create-charge-port-door-close - — Open the charge port
tesla-pp-cli vehicles create-charge-port-door-open - — Set charge limit to Standard (~90%)
tesla-pp-cli vehicles create-charge-standard - — Start charging
tesla-pp-cli vehicles create-charge-start - — Stop charging
tesla-pp-cli vehicles create-charge-stop - — Climate keeper mode: 0=off, 1=on, 2=dog, 3=camp
tesla-pp-cli vehicles create-climate-keeper-mode - — POST /api/1/vehicles/{vehicle_id}/command/door_lock
tesla-pp-cli vehicles create-door-lock - — POST /api/1/vehicles/{vehicle_id}/command/door_unlock
tesla-pp-cli vehicles create-door-unlock - — Erase guest-session user data
tesla-pp-cli vehicles create-erase-user-data - — Flash headlights
tesla-pp-cli vehicles create-flash-lights - — Enable/disable Guest mode
tesla-pp-cli vehicles create-guest-mode - — POST /api/1/vehicles/{vehicle_id}/jwt/hermes
tesla-pp-cli vehicles create-hermes - — Honk the horn
tesla-pp-cli vehicles create-honk-horn - — Toggle max defrost
tesla-pp-cli vehicles create-max-defrost - — Next favorite station
tesla-pp-cli vehicles create-media-next-favorite - — Next track
tesla-pp-cli vehicles create-media-next-track - — Previous favorite station
tesla-pp-cli vehicles create-media-prev-favorite - — Previous track
tesla-pp-cli vehicles create-media-prev-track - — Toggle play/pause
tesla-pp-cli vehicles create-media-toggle-playback - — Volume down
tesla-pp-cli vehicles create-media-volume-down - — Volume up
tesla-pp-cli vehicles create-media-volume-up - — Send lat/lng directly to navigation
tesla-pp-cli vehicles create-navigation-gps-request - — POST /api/1/vehicles/{vehicle_id}/command/remote_start_drive
tesla-pp-cli vehicles create-remote-start-drive - — Remove charging schedule by id
tesla-pp-cli vehicles create-remove-charge-schedule - — Remove preconditioning schedule by id
tesla-pp-cli vehicles create-remove-precondition-schedule - — Reset Valet PIN
tesla-pp-cli vehicles create-reset-valet-pin - — Schedule the pending software update
tesla-pp-cli vehicles create-schedule-software-update - — Set seat heater level (0-3) at a seat position (0=driver, 1=passenger, 2-5=rear)
tesla-pp-cli vehicles create-seat-heater-request - — Set charge limit percent (50-100)
tesla-pp-cli vehicles create-set-charge-limit - — Set charging amps draw
tesla-pp-cli vehicles create-set-charging-amps - — Enable/disable Sentry mode
tesla-pp-cli vehicles create-set-sentry-mode - — Set driver and passenger climate temps (Celsius)
tesla-pp-cli vehicles create-set-temps - — Enable/disable Valet mode with optional PIN
tesla-pp-cli vehicles create-set-valet-mode - — Send navigation destination to the car (address or coordinates)
tesla-pp-cli vehicles create-share - — Activate Speed Limit mode
tesla-pp-cli vehicles create-speed-limit-activate - — Clear Speed Limit PIN
tesla-pp-cli vehicles create-speed-limit-clear-pin - — Deactivate Speed Limit mode
tesla-pp-cli vehicles create-speed-limit-deactivate - — Set Speed Limit value (mph)
tesla-pp-cli vehicles create-speed-limit-set-limit - — Toggle steering wheel heater
tesla-pp-cli vehicles create-steering-wheel-heater-request - — Sun roof: state = vent | close
tesla-pp-cli vehicles create-sun-roof-control - — Trigger HomeLink garage door
tesla-pp-cli vehicles create-trigger-homelink - — Wake the vehicle from sleep
tesla-pp-cli vehicles create-wake-up - — Vent or close all windows; command = vent | close
tesla-pp-cli vehicles create-window-control - — Compose a rendered image of the configured vehicle
tesla-pp-cli vehicles get-compose-image - — Charge state subset (faster than full vehicle_data)
tesla-pp-cli vehicles get-data-charge-state - — Climate state subset
tesla-pp-cli vehicles get-data-climate-state - — Drive state (location, speed, shift) subset
tesla-pp-cli vehicles get-data-drive-state - — GUI settings (units, time format)
tesla-pp-cli vehicles get-data-gui-settings - — Vehicle config (model, options, trim)
tesla-pp-cli vehicles get-data-vehicle-config - — Vehicle state (locks, software, sentry) subset
tesla-pp-cli vehicles get-data-vehicle-state - — Is mobile control enabled in the car
tesla-pp-cli vehicles get-mobile-enabled - — Nearby Supercharger sites with stall availability subfield
tesla-pp-cli vehicles get-nearby-chargers - — Release notes for the current/queued software update
tesla-pp-cli vehicles get-release-notes - — Open service appointments and recent service history for this vehicle
tesla-pp-cli vehicles get-service-data - — Full vehicle state snapshot: charge, climate, drive, GUI, vehicle config, and software
tesla-pp-cli vehicles get-vehicle-data
charging — 超级充电桩队列位置与充电状态
- — 当前超级充电桩队列位置(车位编号、预计等待时间)
tesla-pp-cli charging
diagnostics — 车辆诊断功能配置
- — 车辆诊断功能标志
tesla-pp-cli diagnostics
energy_sites — Powerwall与太阳能发电站配置
- — 设置Powerwall备用储备百分比
tesla-pp-cli energy_sites create-set-backup-reserve - — 设置Powerwall运行模式
tesla-pp-cli energy_sites create-set-operation - — 每日/月度历史能源数据
tesla-pp-cli energy_sites get-calendar-history - — Powerwall太阳能/电网/电池实时功率
tesla-pp-cli energy_sites get-live-status - — Powerwall调度用的电价方案
tesla-pp-cli energy_sites get-rate-tariffs - — 发电站配置(容量、类型、地址)
tesla-pp-cli energy_sites get-site-info - — 备用储备与运行模式
tesla-pp-cli energy_sites get-site-status
logs — 客户端遥测接收器
- — 转发客户端日志事件(主要供内部使用)
tesla-pp-cli logs
notification_preferences — 推送通知设置
- — 更新推送通知偏好设置
tesla-pp-cli notification_preferences
products — 用户拥有的车辆、Powerwall与太阳能产品
- — 列出用户拥有的车辆、Powerwall与太阳能产品
tesla-pp-cli products
users — 账户配置、功能标志、订单以及钥匙/凭证管理
- — 添加虚拟手机钥匙或BLE钥匙
tesla-pp-cli users create-keys - — 移动应用功能标志与运行时配置
tesla-pp-cli users get-app-config - — 账户级功能权限
tesla-pp-cli users get-feature-config - — Tesla订单(新车交付、配件购买)
tesla-pp-cli users get-orders
vehicles — 单车辆数据、空调、锁车、远程启动以及Hermes遥测令牌
- — 打开/关闭后备箱或前备箱;which_trunk 参数可选 front | rear
tesla-pp-cli vehicles create-actuate-trunk - — 添加充电计划(位置+时间窗口)
tesla-pp-cli vehicles create-add-charge-schedule - — 添加预调节计划
tesla-pp-cli vehicles create-add-precondition-schedule - — 设置音量至指定级别
tesla-pp-cli vehicles create-adjust-volume - — POST /api/1/vehicles/{vehicle_id}/command/auto_conditioning_start
tesla-pp-cli vehicles create-auto-conditioning-start - — POST /api/1/vehicles/{vehicle_id}/command/auto_conditioning_stop
tesla-pp-cli vehicles create-auto-conditioning-stop - — 切换生物武器防御模式(HEPA循环)
tesla-pp-cli vehicles create-bioweapon-mode - — 取消待处理的软件更新
tesla-pp-cli vehicles create-cancel-software-update - — 将充电上限设置为最大续航(100%)
tesla-pp-cli vehicles create-charge-max-range - — 关闭充电口
tesla-pp-cli vehicles create-charge-port-door-close - — 打开充电口
tesla-pp-cli vehicles create-charge-port-door-open - — 将充电上限设置为标准值(约90%)
tesla-pp-cli vehicles create-charge-standard - — 开始充电
tesla-pp-cli vehicles create-charge-start - — 停止充电
tesla-pp-cli vehicles create-charge-stop - — 空调保持模式:0=关闭,1=开启,2=宠物模式,3=露营模式
tesla-pp-cli vehicles create-climate-keeper-mode - — POST /api/1/vehicles/{vehicle_id}/command/door_lock
tesla-pp-cli vehicles create-door-lock - — POST /api/1/vehicles/{vehicle_id}/command/door_unlock
tesla-pp-cli vehicles create-door-unlock - — 清除访客会话用户数据
tesla-pp-cli vehicles create-erase-user-data - — 闪烁车灯
tesla-pp-cli vehicles create-flash-lights - — 启用/禁用访客模式
tesla-pp-cli vehicles create-guest-mode - — POST /api/1/vehicles/{vehicle_id}/jwt/hermes
tesla-pp-cli vehicles create-hermes - — 鸣喇叭
tesla-pp-cli vehicles create-honk-horn - — 切换最大除雾模式
tesla-pp-cli vehicles create-max-defrost - — 切换到下一个收藏电台
tesla-pp-cli vehicles create-media-next-favorite - — 下一曲
tesla-pp-cli vehicles create-media-next-track - — 切换到上一个收藏电台
tesla-pp-cli vehicles create-media-prev-favorite - — 上一曲
tesla-pp-cli vehicles create-media-prev-track - — 切换播放/暂停
tesla-pp-cli vehicles create-media-toggle-playback - — 音量减小
tesla-pp-cli vehicles create-media-volume-down - — 音量增大
tesla-pp-cli vehicles create-media-volume-up - — 将经纬度直接发送到导航系统
tesla-pp-cli vehicles create-navigation-gps-request - — POST /api/1/vehicles/{vehicle_id}/command/remote_start_drive
tesla-pp-cli vehicles create-remote-start-drive - — 通过ID删除充电计划
tesla-pp-cli vehicles create-remove-charge-schedule - — 通过ID删除预调节计划
tesla-pp-cli vehicles create-remove-precondition-schedule - — 重置代客模式PIN码
tesla-pp-cli vehicles create-reset-valet-pin - — 安排待处理的软件更新时间
tesla-pp-cli vehicles create-schedule-software-update - — 设置座椅加热级别(0-3)和座椅位置(0=驾驶员,1=乘客,2-5=后排)
tesla-pp-cli vehicles create-seat-heater-request - — 设置充电上限百分比(50-100)
tesla-pp-cli vehicles create-set-charge-limit - — 设置充电电流
tesla-pp-cli vehicles create-set-charging-amps - — 启用/禁用哨兵模式
tesla-pp-cli vehicles create-set-sentry-mode - — 设置驾驶员和乘客的空调温度(摄氏度)
tesla-pp-cli vehicles create-set-temps - — 启用/禁用代客模式,可选择设置PIN码
tesla-pp-cli vehicles create-set-valet-mode - — 将导航目的地发送到车辆(地址或坐标)
tesla-pp-cli vehicles create-share - — 激活限速模式
tesla-pp-cli vehicles create-speed-limit-activate - — 清除限速模式PIN码
tesla-pp-cli vehicles create-speed-limit-clear-pin - — 停用限速模式
tesla-pp-cli vehicles create-speed-limit-deactivate - — 设置限速值(英里/小时)
tesla-pp-cli vehicles create-speed-limit-set-limit - — 切换方向盘加热
tesla-pp-cli vehicles create-steering-wheel-heater-request - — 天窗控制:state 参数可选 vent | close
tesla-pp-cli vehicles create-sun-roof-control - — 触发HomeLink车库门
tesla-pp-cli vehicles create-trigger-homelink - — 将车辆从睡眠状态唤醒
tesla-pp-cli vehicles create-wake-up - — 通风或关闭所有车窗;command 参数可选 vent | close
tesla-pp-cli vehicles create-window-control - — 生成已配置车辆的渲染图像
tesla-pp-cli vehicles get-compose-image - — 充电状态子集(比完整vehicle_data更快)
tesla-pp-cli vehicles get-data-charge-state - — 空调状态子集
tesla-pp-cli vehicles get-data-climate-state - — 行驶状态(位置、速度、挡位)子集
tesla-pp-cli vehicles get-data-drive-state - — GUI设置(单位、时间格式)
tesla-pp-cli vehicles get-data-gui-settings - — 车辆配置(型号、选项、内饰)
tesla-pp-cli vehicles get-data-vehicle-config - — 车辆状态(锁车、软件、哨兵模式)子集
tesla-pp-cli vehicles get-data-vehicle-state - — 车辆是否启用移动控制
tesla-pp-cli vehicles get-mobile-enabled - — 附近的超级充电桩站点及车位可用情况
tesla-pp-cli vehicles get-nearby-chargers - — 当前/待更新软件的版本说明
tesla-pp-cli vehicles get-release-notes - — 车辆的开放服务预约和近期服务历史
tesla-pp-cli vehicles get-service-data - — 完整的车辆状态快照:充电、空调、行驶、GUI、车辆配置和软件信息
tesla-pp-cli vehicles get-vehicle-data
Finding the right command
查找合适的命令
When you know what you want to do but not which command does it, ask the CLI directly:
bash
tesla-pp-cli which "<capability in your own words>"which02--help当你知道要执行的操作但不知道对应的命令时,可以直接询问CLI:
bash
tesla-pp-cli which "<用你自己的描述说明功能>"which02--helpRecipes
使用示例
Snap then ready
快照+就绪检查
bash
tesla snap --all --json && tesla ready 5YJ3E1EA6XXXXXXXX --jsonCapture vehicle state for every car on the account, then check whether your primary vehicle is ready to drive.
bash
tesla snap --all --json && tesla ready 5YJ3E1EA6XXXXXXXX --json捕获账户下所有车辆的状态,然后检查你的主车辆是否可以出发。
Morning ready check
晨间就绪检查
bash
tesla ready 5YJ3E1EA6XXXXXXXX --json --select ready,blockersOne JSON object: is the car ready to drive, and if not, why not. Use to limit response size for agents.
--selectbash
tesla ready 5YJ3E1EA6XXXXXXXX --json --select ready,blockers返回一个JSON对象:车辆是否可以出发,如果不能,原因是什么。使用参数限制响应大小,适合Agent使用。
--selectMonthly charging-cost report
月度充电成本报告
bash
tesla cost ledger --since 30d --group supercharger,home --json --select total_usd,sessions,kwh_added,supercharger_ratioPer-month breakdown with dotted-path so the agent sees only the rollup fields, not every session.
--selectbash
tesla cost ledger --since 30d --group supercharger,home --json --select total_usd,sessions,kwh_added,supercharger_ratio按月度细分,使用点路径参数,让Agent只看到汇总字段,而非每个会话的详细数据。
--selectPreconditioning before leaving
出发前预调节
bash
tesla vehicles create-auto-conditioning-start 5YJ3E1EA6XXXXXXXX --jsonStart climate preconditioning. Run ten minutes later to confirm cabin warmed up.
tesla ready <vin>bash
tesla vehicles create-auto-conditioning-start 5YJ3E1EA6XXXXXXXX --json启动空调预调节。十分钟后执行确认车内已升温。
tesla ready <vin>Supercharger queue watcher
超级充电桩队列监控
bash
tesla supercharger watch 1000 --free-stalls 2 --watch --jsonSubscribe to free-stall transitions at a saved site; emits one JSON line per transition. Pipe to an agent for alerting.
bash
tesla supercharger watch 1000 --free-stalls 2 --watch --json订阅已保存站点的空闲车位状态变化;每次状态变化输出一行JSON。可通过管道传递给Agent进行告警。
Local SOC history via analytics
通过分析获取本地电池电量历史
bash
tesla-pp-cli analytics --select battery_level,captured_at --limit 30 --jsonPull the 30 most recent vehicle-state rows from the local SQLite for trend analysis; same data TeslaMate would surface in Grafana.
bash
tesla-pp-cli analytics --select battery_level,captured_at --limit 30 --json从本地SQLite数据库提取最近30条车辆状态记录用于趋势分析;与TeslaMate在Grafana中展示的数据相同。
Recipe: Remote unlock from anywhere (Fleet path)
示例:从任何地方远程解锁(Fleet路径)
bash
tesla auth fleet-template --gen-key --dest ./tesla-keys-host
cd tesla-keys-host && vercel deploy --prodbash
tesla auth fleet-template --gen-key --dest ./tesla-keys-host
cd tesla-keys-host && vercel deploy --prodRegister the resulting <your-host>.vercel.app at developer.tesla.com, copy client_id and client_secret.
在developer.tesla.com注册生成的<your-host>.vercel.app,复制client_id和client_secret。
tesla auth fleet-register --public-key-domain <your-host>.vercel.app --client-id <id> --client-secret-file <secret-file>
tesla auth fleet-login
tesla command unlock --vehicle Stella --send
Run once to scaffold the public-key host, deploy it, register at Tesla, and complete user OAuth. After that, `unlock` (and any other signed command) works from anywhere with internet. Per-call cost: $0.001 plus a $0.02 wake if the car is asleep. Inside the $10/mo personal-use credit, that lands at roughly $0 net.tesla auth fleet-register --public-key-domain <your-host>.vercel.app --client-id <id> --client-secret-file <secret-file>
tesla auth fleet-login
tesla command unlock --vehicle Stella --send
只需执行一次即可搭建公钥主机、部署、在Tesla注册并完成用户OAuth。之后,`unlock`(以及任何其他签名命令)在任何有互联网的地方都可以使用。每次调用成本:0.001美元,若车辆处于睡眠状态则额外收取0.02美元唤醒费用。在每月10美元的个人使用额度内,实际成本约为0美元。Recipe: Cheap remote charge control via Hermes
示例:通过Hermes实现低成本远程充电控制
bash
tesla auth login --via tesla-auth
tesla auth ble-pair --vin <your-vin>
go install github.com/teslamotors/vehicle-command/cmd/tesla-http-proxy@latest
tesla-http-proxy -key-file ~/.config/tesla-pp-cli/private.pem -port 4443 -cert auto &
tesla relay start
tesla command set-charge-limit --vehicle Snowflake --percent 80 --sendiOS-app PKCE login, one-time BLE key enrollment at the car, then a local proxy plus relay. Subsequent , , , and ride free over Hermes. Unlock and trunk are not available on this path; for those, use Fleet.
tesla command set-charge-limittesla command climate-ontesla command honktesla command media-toggle-playbackbash
tesla auth login --via tesla-auth
tesla auth ble-pair --vin <your-vin>
go install github.com/teslamotors/vehicle-command/cmd/tesla-http-proxy@latest
tesla-http-proxy -key-file ~/.config/tesla-pp-cli/private.pem -port 4443 -cert auto &
tesla relay start
tesla command set-charge-limit --vehicle Snowflake --percent 80 --send通过iOS应用PKCE登录,在车辆上进行一次性BLE钥匙注册,然后启动本地代理和中继。后续的、、和可通过Hermes免费执行。解锁和后备箱控制在此路径不可用;若需要这些功能,请使用Fleet路径。
tesla command set-charge-limittesla command climate-ontesla command honktesla command media-toggle-playbackRecipe: Switching between paths
示例:在不同路径间切换
The flag picks which transport handles a signed command:
--viabash
tesla command set-charge-limit --vehicle Snowflake --percent 80 --send --via hermes
tesla command unlock --vehicle Stella --send --via fleet
tesla command flash-lights --vehicle Snowflake --send --via bleDefaults: pre-2021 vehicles use REST, post-2021 vehicles use whichever signed path is enrolled. If both Hermes and Fleet are enrolled, Hermes wins for infotainment commands (cheaper) and Fleet wins for unlock/lock/trunk (Hermes does not carry these). Override per-call with .
--via--viabash
tesla command set-charge-limit --vehicle Snowflake --percent 80 --send --via hermes
tesla command unlock --vehicle Stella --send --via fleet
tesla command flash-lights --vehicle Snowflake --send --via ble默认规则:2021年前的车辆使用REST,2021年后的车辆使用已注册的任一签名路径。如果同时注册了Hermes和Fleet,信息娱乐命令使用Hermes(成本更低),解锁/锁车/后备箱控制使用Fleet(Hermes不支持这些命令)。可通过参数逐次调用覆盖默认规则。
--viaRecipe: Deploy your tesla agent to a cloud Mac mini
示例:将你的Tesla Agent部署到云端Mac mini
bash
undefinedbash
undefinedOn laptop:
在笔记本电脑上:
tesla auth export --out tesla-bundle.enc
scp tesla-bundle.enc user@mac-mini:~/
tesla auth export --out tesla-bundle.enc
scp tesla-bundle.enc user@mac-mini:~/
On Mac mini:
在Mac mini上:
tesla auth import ~/tesla-bundle.enc
tesla command honk --vehicle Snowflake --send --via fleet
Export creates an Argon2id plus AES-256-GCM bundle of the REST bearer, the Fleet bearer, and the enrolled ECDSA keypair. Copy it over Tailscale or any secure channel. Import on the remote, enter the passphrase, and the same Fleet creds plus the same enrolled key work from the new host. The car does not need to re-enroll; key identity rides on the keypair.tesla auth import ~/tesla-bundle.enc
tesla command honk --vehicle Snowflake --send --via fleet
导出命令会创建一个包含REST令牌、Fleet令牌和已注册ECDSA密钥对的Argon2id + AES-256-GCM加密包。通过Tailscale或任何安全通道复制到远程主机。在远程主机上导入,输入密码,相同的Fleet凭证和已注册密钥即可在新主机上使用。车辆无需重新注册;密钥身份由密钥对保证。Path-decision flowchart
路径决策流程图
Text form (rendered consistently across SKILL.md viewers):
Is the vehicle pre-2021?
Yes -> REST (default path, no extra setup)
No -> Continue.
Is the car within Bluetooth range of this host?
Yes -> BLE (free, all commands, no internet needed)
No -> Continue.
Do you need unlock, lock, trunk, or another non-infotainment signed command?
Yes -> Fleet API (roughly $0/mo within personal-use credit)
No -> Hermes (free, infotainment commands only)
Deploying to a second host (cloud Mac mini, Pi)?
Use the chosen path above, then `tesla auth export` and `tesla auth import` on the remote.文本形式(在所有SKILL.md查看器中显示一致):
车辆是2021年前的型号吗?
是 -> 使用REST(默认路径,无需额外设置)
否 -> 继续。
车辆是否在主机的蓝牙范围内?
是 -> 使用BLE(免费,支持所有命令,无需互联网)
否 -> 继续。
你需要解锁、锁车、后备箱控制或其他非信息娱乐类签名命令吗?
是 -> 使用Fleet API(在个人使用额度内约0美元/月)
否 -> 使用Hermes(免费,仅支持信息娱乐命令)
部署到第二台主机(云端Mac mini、树莓派)?
使用上述选择的路径,然后在远程主机上执行`tesla auth export`和`tesla auth import`。Auth Setup
认证设置
Run and the CLI opens Tesla's real login page in your browser. Log in there (Tesla owns MFA, captcha, SMS codes - we never see them), Tesla redirects you to a 404 page on auth.tesla.com after success, you paste that URL back here. The CLI extracts the auth code via PKCE, exchanges it for tokens, and stores them in (mode 0600). Bearer tokens last 8h; the CLI silently re-mints them on 401 using the long-lived refresh token, so once you log in you don't need to think about it. Headless / CI fallbacks: reads a pre-captured refresh token from stdin, skips stdin, and subprocesses into adriankumpf/tesla_auth (if you have it installed and prefer the native window). Newer vehicles on Tesla's signed-command protocol need separate key enrollment - see for diagnosis.
tesla auth login~/.config/tesla-pp-cli/config.tomlauth login --pasteauth login --refresh-token <tok>auth login --via tesla-authtesla reachabilityRun to verify setup.
tesla-pp-cli doctor执行,CLI会在浏览器中打开Tesla的真实登录页面。在此登录(Tesla负责MFA、验证码、短信验证——我们不会获取这些信息),登录成功后Tesla会将你重定向到auth.tesla.com的404页面,你需要将该URL粘贴回CLI。CLI会通过PKCE提取授权码,换取令牌,并将令牌存储在(权限模式0600)中。Bearer令牌有效期为8小时;当遇到401错误时,CLI会使用长期刷新令牌自动重新生成令牌,因此登录后无需再关注认证问题。无头/CI环境备用方案:从标准输入读取预先捕获的刷新令牌,跳过标准输入,会调用adriankumpf/tesla_auth(如果你已安装并偏好原生窗口)。使用Tesla签名命令协议的较新车辆需要单独注册密钥——请查看进行诊断。
tesla auth login~/.config/tesla-pp-cli/config.tomlauth login --pasteauth login --refresh-token <tok>auth login --via tesla-authtesla reachability执行验证设置是否正确。
tesla-pp-cli doctorAgent Mode
Agent模式
Add to any command. Expands to: .
--agent--json --compact --no-input --no-color --yes-
Pipeable — JSON on stdout, errors on stderr
-
Filterable —keeps a subset of fields. Dotted paths descend into nested structures; arrays traverse element-wise. Critical for keeping context small on verbose APIs:
--selectbashtesla-pp-cli charging --agent --select id,name,status -
Previewable —shows the request without sending
--dry-run -
Offline-friendly — sync/search commands can use the local SQLite store when available
-
Non-interactive — never prompts, every input is a flag
-
Explicit retries — useonly when an already-existing create should count as success
--idempotent
在任何命令后添加参数。该参数等效于:。
--agent--json --compact --no-input --no-color --yes-
可管道传输 — 标准输出为JSON,错误输出到标准错误
-
可过滤 —参数保留字段子集。点路径可深入嵌套结构;数组可遍历每个元素。对于冗长的API,这是保持上下文简洁的关键:
--selectbashtesla-pp-cli charging --agent --select id,name,status -
可预览 —参数显示请求但不发送
--dry-run -
离线友好 — 同步/搜索命令在可用时可使用本地SQLite存储
-
非交互式 — 从不提示,所有输入均通过标志传递
-
显式重试 — 仅当已存在的创建操作应视为成功时,使用参数
--idempotent
Response envelope
响应信封
Commands that read from the local store or the API wrap output in a provenance envelope:
json
{
"meta": {"source": "live" | "local", "synced_at": "...", "reason": "..."},
"results": <data>
}Parse for data and to know whether it's live or local. A human-readable summary is printed to stderr only when stdout is a terminal AND no machine-format flag (, , , , , ) is set — piped/agent consumers and explicit-format runs get pure JSON on stdout.
.results.meta.sourceN results (live)--json--csv--compact--quiet--plain--select从本地存储或API读取数据的命令会将输出包装在来源信封中:
json
{
"meta": {"source": "live" | "local", "synced_at": "...", "reason": "..."},
"results": <data>
}解析获取数据,可判断数据是实时的还是本地的。只有当标准输出是终端且未设置机器格式标志(、、、、、)时,才会在标准错误输出打印人类可读的摘要——管道/Agent消费者和显式格式运行会在标准输出获取纯JSON。
.results.meta.source--json--csv--compact--quiet--plain--selectN results (live)Agent Feedback
Agent反馈
When you (or the agent) notice something off about this CLI, record it:
tesla-pp-cli feedback "the --since flag is inclusive but docs say exclusive"
tesla-pp-cli feedback --stdin < notes.txt
tesla-pp-cli feedback list --json --limit 10Entries are stored locally at . They are never POSTed unless is set AND either is passed or . Default behavior is local-only.
~/.tesla-pp-cli/feedback.jsonlTESLA_FEEDBACK_ENDPOINT--sendTESLA_FEEDBACK_AUTO_SEND=trueWrite what surprised you, not a bug report. Short, specific, one line: that is the part that compounds.
当你(或Agent)发现此CLI存在问题时,请记录:
tesla-pp-cli feedback "the --since flag is inclusive but docs say exclusive"
tesla-pp-cli feedback --stdin < notes.txt
tesla-pp-cli feedback list --json --limit 10反馈条目存储在本地文件中。除非设置了且传递了参数或设置,否则不会发送到服务器。默认行为仅存储在本地。
~/.tesla-pp-cli/feedback.jsonlTESLA_FEEDBACK_ENDPOINT--sendTESLA_FEEDBACK_AUTO_SEND=true请记录让你感到意外的内容,而非提交错误报告。简短、具体、一行内容:这才是有价值的反馈。
Output Delivery
输出交付
Every command accepts . The output goes to the named sink in addition to (or instead of) stdout, so agents can route command results without hand-piping. Three sinks are supported:
--deliver <sink>| Sink | Effect |
|---|---|
| Default; write to stdout only |
| Atomically write output to |
| POST the output body to the URL ( |
Unknown schemes are refused with a structured error naming the supported set. Webhook failures return non-zero and log the URL + HTTP status on stderr.
每个命令都支持参数。输出会发送到指定的接收器,同时(或替代)输出到标准输出,因此Agent无需手动管道即可路由命令结果。支持三种接收器:
--deliver <sink>| 接收器 | 效果 |
|---|---|
| 默认;仅输出到标准输出 |
| 原子性地将输出写入 |
| 将输出体POST到指定URL( |
不支持的协议会返回结构化错误,并列出支持的接收器类型。Webhook失败会返回非零退出码,并在标准错误输出记录URL和HTTP状态码。
Named Profiles
命名配置文件
A profile is a saved set of flag values, reused across invocations. Use it when a scheduled agent calls the same command every run with the same configuration - HeyGen's "Beacon" pattern.
tesla-pp-cli profile save briefing --json
tesla-pp-cli --profile briefing charging
tesla-pp-cli profile list --json
tesla-pp-cli profile show briefing
tesla-pp-cli profile delete briefing --yesExplicit flags always win over profile values; profile values win over defaults. lists all available profiles under so introspecting agents discover them at runtime.
agent-contextavailable_profiles配置文件是一组保存的标志值,可在多次调用中重复使用。当调度Agent每次运行都使用相同配置调用同一命令时,可使用此功能——即HeyGen的“Beacon”模式。
tesla-pp-cli profile save briefing --json
tesla-pp-cli --profile briefing charging
tesla-pp-cli profile list --json
tesla-pp-cli profile show briefing
tesla-pp-cli profile delete briefing --yes显式标志始终优先于配置文件值;配置文件值优先于默认值。会在下列出所有可用配置文件,因此自省Agent可在运行时发现它们。
agent-contextavailable_profilesExit Codes
退出码
| Code | Meaning |
|---|---|
| 0 | Success |
| 2 | Usage error (wrong arguments) |
| 3 | Resource not found |
| 4 | Authentication required |
| 5 | API error (upstream issue) |
| 7 | Rate limited (wait and retry) |
| 10 | Config error |
| 代码 | 含义 |
|---|---|
| 0 | 成功 |
| 2 | 使用错误(参数错误) |
| 3 | 资源未找到 |
| 4 | 需要认证 |
| 5 | API错误(上游问题) |
| 7 | 速率限制(等待后重试) |
| 10 | 配置错误 |
Argument Parsing
参数解析
Parse :
$ARGUMENTS- Empty, , or
help→ show--helpoutputtesla-pp-cli --help - Starts with → ends with
install→ MCP installation; otherwise → see Prerequisites abovemcp - Anything else → Direct Use (execute as CLI command with )
--agent
解析:
$ARGUMENTS- 为空、或
help→ 显示--help输出tesla-pp-cli --help - 以开头 → 以
install结尾 → MCP安装;否则 → 请参阅顶部的前置条件mcp - 其他内容 → 直接使用(以标志执行CLI命令)
--agent
MCP Server Installation
MCP服务器安装
Install the MCP binary from this CLI's published public-library entry or pre-built release, then register it:
bash
claude mcp add tesla-pp-mcp -- tesla-pp-mcpVerify:
claude mcp list从此CLI已发布的公共库条目或预构建版本安装MCP二进制文件,然后注册:
bash
claude mcp add tesla-pp-mcp -- tesla-pp-mcp验证:
claude mcp listDirect Use
直接使用
- Check if installed: If not found, offer to install (see Prerequisites at the top of this skill).
which tesla-pp-cli - Match the user query to the best command from the Unique Capabilities and Command Reference above.
- Execute with the flag:
--agentbashtesla-pp-cli <command> [subcommand] [args] --agent - If ambiguous, drill into subcommand help: .
tesla-pp-cli <command> --help
- 检查是否已安装:如果未找到,提供安装选项(请参阅顶部的前置条件)。
which tesla-pp-cli - 将用户查询与上述独特功能和命令参考中的最佳命令匹配。
- 以标志执行:
--agentbashtesla-pp-cli <command> [subcommand] [args] --agent - 如果存在歧义,查看子命令帮助:。
tesla-pp-cli <command> --help