Drivers
This section of the API is for managing your delivery personnel master data.
It includes driver’s:
Contact details
Delivery personnel defined skills when available.
Restricted or allowed vehicles.
Delivery personnel availability schedule
Rest times and remaining driving hours when available.
Additionally, it empowers you to update each set of information individually.
Driver Object
To create a new driver, the below-listed information details should be presented, starting with the ID, code, and name of the driver, in addition to other information about the driver when applicable.
Attributes Description
Driver Object
Attribute | Data Type | Required | Description |
---|---|---|---|
| String | Required | Unique identifier for the driver |
| String | Required | Unique code for the driver |
| String | Required | Name of the driver |
| String | - | Contact number of the driver |
| Object of driver skills | - | Driver Skills is holding various skills possessed by the driver |
| Object of remaining driving hours | - | RemainingDrivingHours holding details about rest and remaining driving hours for this driver based on what is reported from the board computer when applicable |
| Object of schdule info | - | Availability details of the driver to include his working shifts and exclude any off days |
| List of strings | - | List of certain vehicle codes that are only allowed for the driver |
Driver Skills
Through driver skills, the driver will be identified with all or a subset of these skills, like his license type, his ability to deliver risky goods, and his speaking language. A driver with specific skills may be needed to fulfill shipments that require these skills
Attribute | Data Type | Required | Description |
---|---|---|---|
| Boolean | - | Indicates if the driver has a first-degree license |
| Boolean | - | Indicates if the driver can transport dangerous goods |
| Boolean | - | Indicates if the driver is a Dutch speaker |
| Boolean | - | Indicates if the driver is an English speaker |
| Boolean | - | Indicates if the driver has ADR training certificate |
| Boolean | - | Indicates if the driver has a forklift license |
Remaining Driving Hours
This function updates the system with the driver status of rest and remaining driving hours as it comes from the board computer at a certain moment.
Attribute | Data Type | Required | Description |
---|---|---|---|
| Number | - | Remaining driving time within the current block |
| Number | - | Required rest time after the current block |
| Number | - | Remaining driving time within the current day |
| Number | - | Remaining driving time within the current week |
| Number | - | Remaining driving time within the next two weeks |
| String | - | The timestamp of the event |
| String | - | ID of the card. |
| Boolean | - | Indicates if it's a co-driver |
| String | - | ID of the co-driver's card |
| Boolean | - | Status of the card |
| Number | - | Activity indicator |
| Number | - | Duration of the activity |
| String | - | Timestamp indicating the start of the day |
| Number | - | Break time during drive |
| Number | - | Continuous driving time |
| Number | - | Alarm for continuous driving time |
| Number | - | Driving time within the day |
| Number | - | Alarm for driving time within the day |
| Number | - | Disposable driving time within the day |
| Number | - | Alarm for disposable driving time within the day |
| Number | - | Rest time within the day |
| Number | - | Driving time within the week |
| Number | - | Alarm for driving time within the week |
| Number | - | Disposable driving time within the week |
| Number | - | Alarm for disposable driving time within the week |
| Number | - | Disposable driving time within the next two weeks. |
| Number | - | Labour time within the week. |
| Number | - | Alarm for labour time within the week |
| Number | - | Extended driving time |
| Number | - | Alarm for extended driving time |
| Number | - | Reduced day rests |
| Number | - | Alarm for reduced day rests |
| Number | - | Maximum allowed driving time within the day |
| Number | - | Maximum allowed driving time within the week |
| Number | - | Maximum allowed driving time within the next two weeks |
| Number | - | Remaining driving pause time |
Availability
Availability represents the schedule info of the driver working shifts and when he would be available to execute a planned trip.
Attribute | Data Type | Required | Description |
---|---|---|---|
| List | - | List of time windows for availability |
| Datetime | - | The date of the time window |
| List | - | List of time slots within the time window |
| Time | - | The start time of the time slot |
| Time | - | The end time of the time slot |
Restricted Vehicle Codes
Restricted Vehicle Codes are like special labels for certain vehicles, indicating specific rules or conditions they need to follow.
Attribute | Data Type | Required | Description |
---|---|---|---|
| List of strings | - | List of restricted vehicle codes |
Descriptive Response Object
This object is indicating the overall success or failure.
Attribute | Data Type | Required | Description |
---|---|---|---|
| String | Required | The response message. |
| Boolean | Required | Indicates if an error occurred. |
| String | - | The error message (if IsErrorState is true). |
| String | - | The error code (if IsErrorState is true). |
Available Endpoints
Send Driver
POST
https://api.normalive.ai/SendDriver
This endpoint will add a new driver if its ID doesn’t exist and will update it if it already exists.
Headers
Name | Type | Description |
---|---|---|
authentication * | String | Bearer token acquired after authentication |
Request Body
Name | Type | Description |
---|---|---|
Driver* | Object | Driver Object |
Example
In this example, a request is made to send driver details, including ID, code, name, etc. Send Driver will internally handle if the driver is new or already exists, and therefore the driver data will be updated.
Response
Update Driver Availability
POST
https://api.normalive.ai/UpdateDriverAvailability
This endpoint is for updating the availability of the driver.
Headers
Name | Type | Description |
---|---|---|
Authorization* | String | Bearer token acquired after authentication |
Request Body
Name | Type | Description |
---|---|---|
driverID* | String | Driver ID |
availability* | Object | Availability object |
Update Driver Remaining Hours
POST
https://api.normalive.ai/UpdateDriverRemainingHours
Updating the driver's occupation and remaining time.
Headers
Name | Type | Description |
---|---|---|
Authorization* | String | Bearer token acquired after authentication |
Request Body
Name | Type | Description |
---|---|---|
driverID* | String | Driver ID |
remainingDrivingHours* | Object | Remaining Driving hours Object |
Update Driver Data
POST
https://api.normalive.ai/UpdateDriverData
This endpoint is for any changes or updates in the main driver's data.
Headers
Name | Type | Description |
---|---|---|
Authorization* | String | Bearer token acquired after authentication |
Request Body
Name | Type | Description |
---|---|---|
id* | String | Driver ID |
code* | String | Driver Code |
name* | String | Driver's Name |
phone | String | Driver's phone number |
driverSkills | Object | Driver skills object |
restrictedVehicles | List of strings | List of vehicle codes that are restricted to the driver |
Delete Driver
POST
https://api.normalive.ai/DeleteDriver
Endpoint for deleting a driver from your system.
Headers
Name | Type | Description |
---|---|---|
Authorization* | String | Bearer token acquired after authentication |
Request Body
Name | Type | Description |
---|---|---|
driverId* | String | Driver ID |
Last updated