The GET Driver by ID API endpoint allows you to retrieve detailed information about a specific driver using their unique ID. This endpoint provides comprehensive data about the driver, facilitating effective driver management and tracking within the Alvys system.
The endpoint for retrieving a driver by ID requires specifying the driver's unique ID and the API version in the URL path. This ensures that your application interacts with the correct driver's data and the appropriate version of the API, providing stability and compatibility as the API evolves. For more information on how versioning works and how to include it in your requests, please refer to the Versioning page.
Request Parameters
The following parameters are required in the URL path:
Parameter | Type | Required | Description |
---|---|---|---|
version | String | Yes | The API version to use. |
id | String | Yes | The unique Alvys identifier of the driver. |
Example CURL request
curl --location 'https://integrations.alvys.com/api/p/v{version}/drivers/{id}' \
--header 'Authorization: Bearer YOUR_ACCESS_TOKEN'
Replace {version}
with the API version number, {id}
with the actual driver ID, and YOUR_ACCESS_TOKEN
with your actual Bearer token:
curl --location 'https://integrations.alvys.com/api/p/v1/drivers/DR123456789' \
--header 'Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJjaWQiOiJBTDM2MyIsInZlc...'
Response Parameters
The following table lists the parameters included in the response for driver-related requests.
Parameter | Type | Required | Description |
---|---|---|---|
id | String | Yes | The unique identifier of the driver. |
employeeId | String | No | The employee ID of the driver. |
phoneNumber | String | No | The phone number of the driver. |
userId | String | No | The user ID associated with the driver. |
String | No | The email address of the driver. | |
name | String | No | The name of the driver. |
type | String | No | The type of driver (e.g., Full-time, Part-time). |
subsidiaryId | String | No | The subsidiary ID to which the driver belongs. |
address | Object | No | The address details of the driver. |
address.street | String | No | The street address of the driver. |
address.city | String | No | The city of the driver's address. |
address.state | String | No | The state of the driver's address. |
address.zipCode | String | No | The zip code of the driver's address. |
status | String | No | The current status of the driver (e.g., Active, Inactive). |
licenseNum | String | No | The driver's license number. |
licenseState | String | No | The state that issued the driver's license. |
licenseExpiresAt | String (Date-Time) | No | The expiration date of the driver's license. |
medicalExpiresAt | String (Date-Time) | No | The expiration date of the driver's medical certificate. |
hiredAt | String (Date-Time) | No | The date when the driver was hired. |
terminatedAt | String (Date-Time) | No | The date when the driver was terminated, if applicable. |
notes | Array | No | An optional list of notes related to the driver. |
notes.id | String | No | The unique identifier of the note. |
notes.description | String | No | The description of the note. |
notes.noteType | String | No | The type of the note. |
notes.time | String (Date-Time) | No | The time the note was created. |
notes.user | String | No | The user who created the note. |
fleet | Object | No | The fleet information associated with the driver. |
fleet.id | String | No | The unique identifier of the fleet. |
fleet.name | String | No | The name of the fleet. |
createdAt | String (Date-Time) | Yes | The date and time when the driver was created in Alvys. |
Example Response
On the right side, you can see examples of different error codes by clicking "Example" and selecting the response code.
Rate Limits
All endpoints are subject to rate limits to protect the API from traffic spikes. For detailed information on rate limits, please refer to the Rate Limits section.
This page is interactive, allowing you to try a request by providing the driver ID in the URL path. As you fill out the parameters, the Curl command on the right side of the page will be automatically updated. Alternatively, you can directly edit the Curl command. Make sure to authorize yourself before trying a request.