DeveloperSkip to main content

  1. Fleet API
  2. Charging

Fleet Telemetry

Fleet Telemetry allows vehicles to stream data directly to a server, eliminating the need to poll the vehicle_data endpoint. This prevents unnecessary vehicle wakes and battery drain.

While online, vehicles stream telemetry via an mTLS Web Socket connection to a server hosted by the partner application. This is the preferred method for accessing vehicle data.

Server Setup

The fleet-telemetry server must be running on a server exposed to the public internet. The GitHub repository has source code and examples of running the server.

Vehicle Setup

To configure a vehicle, confirm all pre-requisites are met. Then, send a configure Fleet Telemetry request through the vehicle-command HTTP proxy. The proxy will sign the configuration using the configured private key and forward the request to Fleet API.

Prerequisites

For a vehicle to be able to stream data, a few conditions must be met:

  • The vehicle must not be a pre-2021 Model S or Model X.
  • Vehicles must be running firmware version 2024.26 or later.
    • Applications configured with the legacy certificate signing process require 2023.20.6 or later.
  • The Fleet Key is paired with the vehicle.

Pairing a Key

To pair a key to the vehicle, direct the user to:

https://tesla.com/_ak/developer-domain.com

This will allow the user to add the key to their vehicle through the Tesla mobile app.

Troubleshooting:

  • If receiving a message stating the user has not granted this third party app access, ensure the user is logged into the Tesla app with the same email used when authorizing the third party application.
  • If receiving a message stating the application has not registered with Tesla, ensure the register endpoint has been called for the region the user is located in.

Send Configuration

Once all pre-requisites are met, use the Fleet Telemetry configure endpoint to send the desired configuration to the vehicle.

Configure Vehicle Endpoint

Available Fields

A full list of fields are available in the open source repository's vehicle_data.proto file.

Any configuration sent to a vehicle must meet the requirements defined for the user's plan.

When validating a configuration, the field's category is considered. The categories are:

  • Driving
    • VehicleSpeed
    • Odometer
    • Location
    • GpsState
    • GpsHeading
    • PedalPosition
    • BrakePedal
    • BrakePedalPos
    • Gear
    • LateralAcceleration
    • LongitudinalAcceleration
  • Charging
    • TimeToFullCharge
    • ChargeAmps
    • ChargerPhases
    • ChargeState
    • BmsFullchargecomplete
    • DCChargingEnergyIn
    • ACChargingEnergyIn
    • DCChargingPower
    • ACChargingPower
  • Default (any field not defined above)