Diagnostic Webhooks (Early Access)
Diagnostic webhooks send events whenever a state change occurs within the vehicle’s Health Status or a Diagnostic Trouble Code (DTC) is reported
Early Access
Diagnostic webhooks are available in early access throughout December 2024 - January 2025 for organizations with Enterprise plans with Smartcar.
Brand Support
Diagnostics provide visibility into Diagnostic Trouble Codes (DTCs) for GM vehicles and System Status information for GM and FCA vehicles.
Supported Events
Diagnostic Trouble Codes (DTCs), which are 5-digit codes that indicate the component and fault type. DTC webhooks will send events for each active DTC including a timestamp it became active. A webhook event will also trigger when a DTC is no longer active.
System Status, where an OEM application’s “Vehicle Health” or “System Health” reports provide a list of components and their health status. System Status webhooks will send events whenever a system reports a change from Healthy to Alert and vice-versa. A list of diagnostic systems is available in our Help Center.
Prerequisites
For this tutorial it is recommended to have the following in place:
-
To receive webhooks you’ll need to set up a callback URI on your server.
-
To subscribe a vehicle you’ll want to have Connect integrated into your application.
Setting up a Diagnostic Webhook
Navigate to Webhooks from the Smartcar Dashboard, select + Add webhook and select Event-based from the Webhooks config wizard.
Name your webhook and specify a callback URI
. Your callback URI
is where Smartcar will send payloads from vehicles connected to your webhook. Click Next.
Select which event types you wish to receive from System Status or Diagnostic Trouble Codes and hit Add. To receive both event types, create a second webhook.
Hit Add when ready.
After adding your webhook, you’ll need to verify your callback URI. This is to ensure Smartcar is sending data to the correct place!
Please see our API reference on how to verify a webhook, or Part II on this blog post for a more in depth guide.
Subscribing vehicles to a webhook
Now you’ve got your webhook set up, you can subscribe vehicles to start getting data. If you haven’t done so already, please set up Connect for your application.
After going through Connect and receiving your initial access_token
, you’ll first want to hit the All Vehicles endpoint to fetch the Smartcar vehicle_ids
of the authorized vehicles.
With your access_token
and webhook_id
you can hit the Subscribe endpoint for each vehicle_id
to start receiving data.
Example Diagnostic Trouble Code Payload
Response
The unique ID of the event delivered.
The ID for the vehicle.
The ID for the user impacted by the event.
The date and time the event was reported.
Indicates the event is a DTC.
the Diagnostic Trouble Code.
The date and time the DTC became active. ISO 8601, millisecond precision, UTC time zone.
Example System Status Payload
Response
The unique ID of the event delivered.
The ID for the vehicle.
The ID for the user impacted by the event.
The date and time the event was reported.
Indicates the event is a System Alert
the system reporting alert or OK status. See Smartcar Systems.
Either “ALERT” or “OK”.
A plaintext, readable description when available.
The date and time the DTC became active. ISO 8601, millisecond precision, UTC time zone.
FAQs
Was this page helpful?