EV Battery API
Read an electric vehicle’s battery level and battery capacity with simple API requests.
Retrieve the state of charge (SoC) and the remaining range from a battery electric vehicle (BEV) or a plug-in hybrid vehicle (PHEV).
Know the capacity of an electric vehicle’s battery.
const smartcar = require('smartcar');
// Get all vehicles associated with this access token
const {vehicles} = await smartcar.getVehicles("<access-token>");
// Construct a new vehicle instance using the first vehicle's id
const vehicle = new smartcar.Vehicle(vehicles[0], "<access-token>");
// Fetch the vehicle's battery level
const battery = await vehicle.battery();
// Fetch the vehicle's battery capacity
const batteryCapacity = await vehicle.batteryCapacity();
// Example http response from Smartcar (battery level)
{
"percentRemaining": 0.3,
"range": 40.5,
}
// Example http response from Smartcar (battery capacity)
{
"capacity": 28.7,
}
Provide estimated charging times, automatic charging schedules, and EV trip planning in your app.
Learn more about EV chargingManage your customers’ residential EV charging to best balance electric grid load.
Learn more about energy and utilitiesSmartcar is the easiest way to integrate mobility apps and services with cars.