Tessie Tesla Control
Control your Tesla vehicles via the Tessie API - a Tesla management platform with 500,000+ users. Check battery levels, range, location, control climate and charging, and view recent drives.
Prerequisites
Before using this skill, you need:
1. A Tessie account with your Tesla linked
2. A Tessie API key from https://tessie.com/developers
Configuration
The user must provide their Tessie API key. This can be configured via:
**Environment variable:**
```bash
TESSIE_API_KEY="your-tessie-api-key-here"
```
**Or configuration file:**
```yaml
skills:
entries:
tessie:
apiKey: "your-tessie-api-key-here"
```
**Important:** Vehicle ID and VIN are auto-detected from the API. No manual vehicle configuration is needed.
Instructions
When the user requests Tessie/Tesla vehicle operations, follow these steps:
Step 1: Retrieve API Key
Check for the Tessie API key in this order:
1. Environment variable `TESSIE_API_KEY`
2. Configuration file under `skills.entries.tessie.apiKey`
If not found, ask the user to provide their Tessie API key from https://tessie.com/developers
Step 2: Auto-Detect Vehicle
Make a GET request to retrieve the user's vehicles:
```
GET https://api.tessie.com/vehicles
Authorization: Bearer <api-key>
```
The response includes full vehicle data with embedded `last_state`. Extract:
`vin` (used for all commands)`id` (vehicle identifier)`display_name` (for user-friendly output)Store these values for subsequent operations. If multiple vehicles exist, use the first one or ask the user which vehicle to control.
Step 3: Execute User Intent
Parse the user's request and map it to one of these operations:
#### Vehicle Status Operations
**Battery & Range:**
User says: "battery", "charge level", "how much charge"Action: Return `last_state.battery_level` and `last_state.battery_range`**Location:**
User says: "where is my car", "location"Action: Return `last_state.latitude`, `last_state.longitude`, and `last_state.location` if available**Vehicle State:**
User says: "is it locked", "vehicle status"Action: Return `last_state.locked`, `last_state.is_climate_on`, `last_state.charge_state`, `last_state.state` (online/asleep/offline)#### Climate Control Operations
**Start/Stop Climate:**
User says: "turn on climate", "preheat", "precool", "turn off climate"Action: POST to `https://api.tessie.com/{VIN}/command/start_climate` or `stop_climate`**Set Temperature:**
User says: "preheat to 72", "set temperature to 20"Action: POST to `https://api.tessie.com/{VIN}/command/set_temperatures`Body: `{ "driver_temp": <celsius>, "passenger_temp": <celsius> }`**Temperature conversion:** If value > 50, assume Fahrenheit and convert: `(F - 32) * 5/9`**Defrost:**
User says: "defrost"Action: POST to `https://api.tessie.com/{VIN}/command/set_temperatures` with max heat settings#### Charging Operations
**Start/Stop Charging:**
User says: "start charging", "stop charging"Action: POST to `https://api.tessie.com/{VIN}/command/start_charging` or `stop_charging`**Set Charge Limit:**
User says: "set charge limit to 90", "charge to 80%"Action: POST to `https://api.tessie.com/{VIN}/command/set_charge_limit`Body: `{ "percent": <integer> }`**Charging Status:**
User says: "charging status", "how long until charged"Action: Return `last_state.charging_state`, `last_state.charge_rate`, `last_state.time_to_full_charge`#### Drives & History
**Recent Drives:**
User says: "recent drives", "show my drives", "last 5 drives"Action: GET `https://api.tessie.com/{VIN}/drives?limit=10`Display: Start/end locations, distance, energy used, duration**Idle Sessions:**
User says: "parked sessions", "idle times"Action: GET `https://api.tessie.com/{VIN}/idles?limit=10`Display: Parked location, climate/sentry usageStep 4: Present Results
Format the API response into a user-friendly summary. Include:
Current values (battery %, range, temperature)Confirmation of actions taken ("Climate started", "Charging limit set to 90%")Any errors or warnings from the APIAPI Reference
All requests require the Authorization header:
```
Authorization: Bearer <api-key>
```
**Base URL:** `https://api.tessie.com`
**Key Endpoints:**
`GET /vehicles` — List vehicles with embedded state`GET /{VIN}/drives?limit=N` — Recent drive history`GET /{VIN}/idles?limit=N` — Parked sessions`POST /{VIN}/command/{command}` — Execute vehicle command**Common Commands:**
`start_climate`, `stop_climate`, `set_temperatures``start_charging`, `stop_charging`, `set_charge_limit``lock`, `unlock``enable_sentry`, `disable_sentry``activate_front_trunk`, `activate_rear_trunk``open_windows`, `close_windows`, `vent_windows`Full API docs: https://developer.tessie.com
Example Usage
**User:** "What's my battery level?"
**Agent:** Fetches vehicles, reads `last_state.battery_level`, responds: "Your Tesla is at 78% charge with 210 miles of range."
**User:** "Preheat to 72 degrees"
**Agent:** Converts 72°F to 22°C, POSTs to `set_temperatures`, responds: "Climate started. Preheating to 72°F."
**User:** "Show my last 3 drives"
**Agent:** GETs `/drives?limit=3`, formats and displays drive history with distances and energy usage.
Constraints
Tessie acts as a middleman to Tesla's API (not direct Tesla API access)User must have Tesla account linked to Tessie firstVehicle must be awake/online for most commands (wake commands available if needed)All internal temperatures use Celsius; auto-convert if user provides FahrenheitRate limits apply per Tessie's API termsNotes
Vehicle VIN is used for all command endpoints (not vehicle ID)The `last_state` object is embedded in the `/vehicles` response for efficiencyIf vehicle is asleep, some commands may take longer or require waking the car firstAll API responses should be checked for `result: true` to confirm success