Skip to content

List command logs for a vehicle

Request

List the historical command logs for a specific Vehicle. These logs record commands that were sent to the vehicle.

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

The ID of the specific vehicle to retrieve.

Example:vhcl01HRFF3SEVSCRAV9B3CHVDFN0H
Query
page_beforestring[a-z]{4}[A-Z\d]{26}

Return results from the page after this ID.

Example:page_before=xmpl01HNFZM7Q8FXASZXYZ6XM3TQRR
page_afterstring[a-z]{4}[A-Z\d]{26}

Return results from the page before this ID.

Example:page_after=xmpl01HNFZM7Q8FXASZXYZ6XM3TQRR
page_sizeinteger, [ 1 .. 100 ]

Specify the number of results to return per page.

Default:25
Example:page_size=10
logged_at__gtestring, (date-time)

Filters for logs logged at or after this datetime.

Example:logged_at__gte=2024-04-17T09:39:45.984584Z
logged_at__ltestring, (date-time)

Filters for logs logged at or before this datetime.

Example:logged_at__lte=2024-04-17T09:39:45.984584Z
expandArray of strings

Specify a url field to expand into a nested resource.

Items Enum:"vehicle""vehicle.trim""vehicle.trim.model""vehicle.trim.model.make""vehicle.user"
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/command_logs?page_before=xmpl01HNFZM7Q8FXASZXYZ6XM3TQRR&page_after=xmpl01HNFZM7Q8FXASZXYZ6XM3TQRR&page_size=10&logged_at__gte=2024-04-17T09%3A39%3A45.984584Z&logged_at__lte=2024-04-17T09%3A39%3A45.984584Z&expand=vehicle' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'EvEnergy-Version: 2'

Responses

List all the command logs for a specific Vehicle, sorted newest first.

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
Array [
urlstring, (uri)read-only
Example:"https://api.ev.energy/v2/vehicles/vhcl01HRFF3SEVSCRAV9B3CHVDFN0H/command_logs/2024-04-17T09:39:45.984584Z/"
logged_atstring, (date-time)read-only

The date and time when this command was logged by the ev.energy system.

vehiclestring or Vehicle (object)
One of:
string (uri)
commandstringread-only

The type of command that was sent to the vehicle.

Enum:"START_CHARGE""STOP_CHARGE""WAKE_UP""SEND_SCHEDULE"
Example:"START_CHARGE"
external_command_idstring or nullread-only

External command ID from the vehicle provider.

Example:"ext-cmd-12345"
current_milliampsinteger or nullread-only

If a start/stop command was sent, this is the current level that was sent in milliamps.

Example:32000
internal_command_idstring or null, (uuid)read-only

Internal UUID to track this command dispatch. This links with device command logs and error logs.

Example:"a1b2c3d4-e5f6-7890-abcd-ef1234567890"
]
Response
[ { "url": "https://api.ev.energy/v2/vehicles/vhcl01HRFF3SEVSCRAV9B3CHVDFN0H/command_logs/2024-04-17T09:39:45.984584Z/", "logged_at": "2019-08-24T14:15:22Z", "vehicle": "https://api.ev.energy/v2/vehicles/vhcl01HRFF3SEVSCRAV9B3CHVDFN0H", "command": "START_CHARGE", "external_command_id": "ext-cmd-12345", "current_milliamps": 32000, "internal_command_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890" } ]