Get all vehicles
GET {{base_url}}/vehicles
Description
This API endpoint is used to search for vehicles based on various criteria such as country code, page number, page size, model, manufacturer, year, type, license plate, start date, and end date.
Request Headers:
| Name | Description |
|---|---|
| countryCode | (required, header) The country code associated with the request. |
Query Parameters:
| Name | Description |
|---|---|
| pageNumber | Page number for paginated results. |
| pageSize | Number of results per page. |
| model | Filter by vehicle model. |
| manufacturer | Filter by vehicle manufacturer. |
| year | Filter by manufacturing year. |
| type | Filter by vehicle type. |
| licensePlate | Filter by license plate number. |
| startDate | Filter by start date. |
| endDate | Filter by end date. |
Responses:
Status Code 200 Description: Vehicles found successfully.
Response Body Schema:
{
"status": "boolean",
"statusCode": "integer",
"message": "string",
"data": {},
"errors": [
{
"message": "string",
"descriptiveMessage": "string"
}
]
}
Example:
<searchVehiclesResponse>
<status>true</status>
<statusCode>0</statusCode>
<message>string</message>
<data></data>
<errors>
<error>
<message>string</message>
<descriptiveMessage>string</descriptiveMessage>
</error>
</errors>
</searchVehiclesResponse>
400 Bad Request Description: Invalid reference supplied.
404 Not Found Description: Vehicles not found.
LANGUAGE
CURL REQUEST
curl --request GET \
--url /vehicles \
--header 'accept: application/json' \
--header 'content-type: application/json'
RESPONSE
Click Try It! to start a request and see the response here!