Skip to content

Retrieve a vehicle's current state of charge

Request

Retrieve the vehicle's current battery percentage used to seed route plans. source indicates where the value came from: MANUAL when the driver entered it, or CONNECTED when it comes from the vehicle's telemetry. All fields are null when no value is available.

Security
oauth2(Required scopes: vehicle:read)
Path
vehicle_idstringvhcl[A-Z\d]{26}required

The ID of the specific vehicle to retrieve.

Example:vhcl01HRFF3SEVSCRAV9B3CHVDFN0H
Headers
EvEnergy-Versionnumber

Specify the version of this endpoint to use.

Value:2
curl -i -X GET \
  https://developers.ev.energy/_mock/ev.energy-api-v2/vehicles/vhcl01HRFF3SEVSCRAV9B3CHVDFN0H/state_of_charge \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'EvEnergy-Version: 2'

Responses

Returns the vehicle's current state of charge.

Headers
EvEnergy-Versionnumber

Indicates the version of the API that generated this response. If EvEnergy-Version was not specified in the request, this will be your OAuth application's default version.

Value:2
X-RateLimit-Limitnumber

The maximum number of requests that can be made to this endpoint per hour. Defaults to 1000 but may vary per client.

Default:1000
X-RateLimit-Remainingnumber

The number of requests remaining until this client's rate limit is reached.

Default:999
RetryAfternumber

The number of seconds until this client's requests will not be rate limited.

Default:3600
Bodyapplication/json
urlstring, (uri)read-onlyrequired
Example:"https://api.ev.energy/v2/vehicles/vhcl01HRFF3SEVSCRAV9B3CHVDFN0H/state_of_charge"
vehiclestring, (uri)read-onlyrequired
Example:"https://api.ev.energy/v2/vehicles/vhcl01HRFF3SEVSCRAV9B3CHVDFN0H"
state_of_charge_percentageinteger or null, [ 0 .. 100 ]required

Current battery percentage. Null when unknown.

sourcestring or nullread-onlyrequired

Where the current value came from: MANUAL (driver-entered) or CONNECTED (vehicle telemetry). Null when no value is available.

Enum:"MANUAL""CONNECTED"null
updated_atstring or null, (date-time)read-onlyrequired
Response
{ "url": "https://api.ev.energy/v2/vehicles/vhcl01HRFF3SEVSCRAV9B3CHVDFN0H/state_of_charge", "vehicle": "https://api.ev.energy/v2/vehicles/vhcl01HRFF3SEVSCRAV9B3CHVDFN0H", "state_of_charge_percentage": 0, "source": "MANUAL", "updated_at": "2019-08-24T14:15:22Z" }