[Webhook] Vehicle Status Change
This webhook allows the rental company to listen to status change of the vehicles belong to them.
More details about webhooks can be found here.
¶ Resource
To be defined by the rental company. This also needs to be registered in developer dashboard.
¶ HTTP Method
POST
¶ Access Method
None. Auth process defined here.
¶ Request Header Parameters
Defined here
¶ Request Query/Body Parameters
Name | Type | Description |
---|---|---|
event_id |
string | Unique event identifier, which can be used to ensure that events are only digested once. This is a Uber generated UUID. |
event_time |
long | Unix timestamp of the time the event occurred. |
event_type |
string | The type of event that occurred. In this case, value would be VEHICLE_STATUS_UPDATED. |
meta |
object | The object containing additional information that is specific to the event_type. |
¶ Request Query/Body Parameters - Meta
Name | Type | Description |
---|---|---|
resource_id |
string | Unique identifier of the resource this event has been generated for. In this case, it’s vehicle_id. |
vehicle |
object | Contains the details of the vehicle like current status, last modified timestamp, associated documents status etc. |
¶ Request Query/Body Parameters - Vehicle
Name | Type | Description |
---|---|---|
updated_at |
long | Epoch timestamp representing when the vehicle was last modified. |
status |
string | Status of the vehicle. Possible values- [ACTIVE, DEACTIVATED, DELETED]. |
documents |
object_array | Array of document requirement object. |
¶ Request Query/Body Parameters - Document Requirement Object
Name | Type | Description |
---|---|---|
type |
string | Document type of the document for which the status is being returned. |
status |
string | Status of the document - pending, missing, active, expired, rejected. Rental company will need to take action when the status is missing, expired or rejected. |
¶ Example
{
"event_id":"44761ec2-dea9-44b3-8eda-ccf22befaa35",
"event_time":1520394983,
"event_type":"VEHICLE_STATUS_UPDATED",
"meta":{
"resource_id":"vehicle_id",
"vehicle":{
"status":"ACTIVE",
"updated_at":1556542167,
"documents":[
{
"status":"active",
"type":"VehicleRegistration"
},
{
"status":"active",
"type":"VehicleInsurance"
},
]
}
}
}