Cars Search

A search for cars.

created_at
datetime

The date and time when the search was created.

Example: "2024-01-10T14:30:00Z"
driver
object

Information about the driver such as the age and country of residence.

dropoff_date
date

The date when the car will be dropped off.

Example: "2024-01-20"
dropoff_location
object

A search location with geographic coordinates and search radius.

dropoff_time
string

The time the car will be dropped off, in HH:MM format.

Example: "15:00"
id
string

The unique identifier for the car search.

Example: "seh_0000AwrHw8KES5d3z1l0uu"
live_mode
boolean

Indicates whether the search was made in live mode or test mode.

Example: false
pickup_date
date

The date the car will be picked up.

Example: "2024-01-15"
pickup_location
object

A search location with geographic coordinates and search radius.

pickup_time
string

The time the car will be picked up, in HH:MM format.

Example: "10:30"
rates
list

Available rental rates for the search criteria.

Creates a search for rental cars based on the provided criteria, such as pickup and drop-off locations, dates, and times.

Body parameters

driver
objectrequired

Information about the driver such as the age and country of residence.

dropoff_date
daterequired

The date when the car will be dropped off.

Example: "2024-01-20"
dropoff_location
objectrequired

A search location with geographic coordinates and search radius.

dropoff_time
stringrequired

The time the car will be dropped off, in HH:MM format.

Example: "15:00"
pickup_date
daterequired

The date the car will be picked up.

Example: "2024-01-15"
pickup_location
objectrequired

A search location with geographic coordinates and search radius.

pickup_time
stringrequired

The time the car will be picked up, in HH:MM format.

Example: "10:30"

Endpoint

POST https://api.duffel.com/cars/search

Request

curl -X POST --compressed "https://api.duffel.com/cars/search" \
-H "Accept-Encoding: gzip" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Duffel-Version: v2" \
-H "Authorization: Bearer <YOUR_ACCESS_TOKEN>" \
-d '{
"data": {
"pickup_time": "10:30",
"pickup_location": {
"radius": 5,
"geographic_coordinates": {
"longitude": -0.1278,
"latitude": 51.5074
}
},
"pickup_date": "2024-01-15",
"dropoff_time": "15:00",
"dropoff_location": {
"radius": 5,
"geographic_coordinates": {
"longitude": -0.1278,
"latitude": 51.5074
}
},
"dropoff_date": "2024-01-20",
"driver": {
"residence_country_code": "US",
"age": 30
}
}
}'

Response

{
"data": {
"rates": [
{
"total_currency": "GBP",
"total_amount": "101.34",
"supplier": {
"name": "Duffel Test Drive",
"logo_url": "https://duffel.com/logo.jpg"
},
"pickup_location": {
"phone_number": "+44 1234 567890",
"opening_hours": [
{
"to": "20:00",
"from": "08:00"
}
],
"name": "Duffel Test Drive Dropoff",
"geographic_coordinates": {
"longitude": -0.4543,
"latitude": 51.47
},
"address": {
"region": "England",
"postal_code": "W1J 9BR",
"line_one": "150 Piccadilly",
"country_code": "GB",
"city_name": "London"
},
"additional_information": [
{
"title": "Pickup Instructions",
"text": "Please follow the signs to the rental car area."
}
]
},
"payment_type": "guarantee",
"id": "rae_0000Ax4Af0b5l45AT50eqO",
"dropoff_location": {
"phone_number": "+44 1234 567890",
"opening_hours": [
{
"to": "20:00",
"from": "08:00"
}
],
"name": "Duffel Test Drive Dropoff",
"geographic_coordinates": {
"longitude": -0.4543,
"latitude": 51.47
},
"address": {
"region": "England",
"postal_code": "W1J 9BR",
"line_one": "150 Piccadilly",
"country_code": "GB",
"city_name": "London"
},
"additional_information": [
{
"title": "Pickup Instructions",
"text": "Please follow the signs to the rental car area."
}
]
},
"car": {
"type": "four_door",
"transmission": "automatic",
"name": "Kia Picanto",
"max_passengers": 5,
"images": [
{
"url": "https://car.com/kia_picanto.jpg"
}
],
"fuel": "petrol",
"code": "CDAV",
"category": "compact",
"baggage": {
"small": 2,
"large": 3
},
"air_conditioning": true
},
"base_currency": "GBP",
"base_amount": "95.22"
}
],
"pickup_time": "10:30",
"pickup_location": {
"radius": 5,
"geographic_coordinates": {
"longitude": -0.1278,
"latitude": 51.5074
}
},
"pickup_date": "2024-01-15",
"live_mode": false,
"id": "seh_0000AwrHw8KES5d3z1l0uu",
"dropoff_time": "15:00",
"dropoff_location": {
"radius": 5,
"geographic_coordinates": {
"longitude": -0.1278,
"latitude": 51.5074
}
},
"dropoff_date": "2024-01-20",
"driver": {
"residence_country_code": "US",
"age": 30
},
"created_at": "2024-01-10T14:30:00Z"
}
}