Skip to main content
GET
List Vehicles

List Vehicles

Retrieve all vehicles registered in your organization’s fleet with pagination support and flexible filtering options.
This endpoint returns both known vehicles (from our database with specific make/model) and unknown vehicles (custom vehicles defined by the user).

Request

Headers

string
required
Your API key for authenticationExample: sk_live_1234567890abcdef
string
required
Your organization UUIDExample: ff4adcc7-8172-45fe-9cf1-e90a6de53aa9
string
required
Your user UUIDExample: a1b2c3d4-e5f6-7890-abcd-ef1234567890

Query Parameters

integer
default:"1"
Page number for paginationExample: 1
integer
default:"50"
Number of items per page (max: 100)Example: 50
string
Advanced filtering criteria (format: field:value)Example: "country:ES", "type:passenger", "ownership:owned"
string
Sort criteria (format: field:asc or field:desc)Example: "name:asc", "created_at:desc", "license_plate:asc"
integer
Filter by creation date start (Unix timestamp)Example: 1704067200 (January 1, 2024)
integer
Filter by creation date end (Unix timestamp)Example: 1735689600 (January 1, 2025)

Response

integer
Current page number
integer
Number of items per page
integer
Total count of active vehicles
integer
Total count of archived vehicles
array
Array of vehicle objects

Vehicle Object Fields:

  • id (string, UUID) - Unique vehicle identifier
  • name (string, optional) - Vehicle name or description
  • license_plate (string, optional) - Vehicle license plate number
  • type (string) - Vehicle usage type: "passenger" or "freight"
  • ownership (string) - Vehicle ownership: "owned" or "rented"
  • country (string) - ISO 3166-1 alpha-2 country code
  • is_known (boolean) - Whether vehicle is from known database or custom
  • known_vehicle_id (string, UUID, optional) - ID if vehicle from database
  • unknown_vehicle_id (string, UUID, optional) - ID if custom vehicle
  • vehicle_fuel_id (string, UUID, optional) - Associated fuel type ID
  • vehicle_fuel (string, optional) - Fuel type name (e.g., “Diesel”, “Electric”)
  • registration_year (integer, optional) - Year vehicle was first registered
  • market_segment (string, optional) - Vehicle market segment
  • size (string, optional) - Vehicle size classification
  • co2e (float) - Total CO2 equivalent emissions in kg
  • consumptions (integer, optional) - Number of fuel consumption records
  • status (string) - "active", "archived", or "error"
  • error_messages (array of strings, optional) - Error messages if status is error
  • created_at (datetime) - Creation timestamp
  • known_vehicle (object, optional) - Details if known vehicle
    • id (string) - Known vehicle database ID
    • brand (string) - Vehicle manufacturer
    • model (string) - Vehicle model
    • country (string) - Country code
    • vehicle_motor_type (string) - Motor type
    • gearbox_type (string) - Transmission type
    • cylinder_capacity (integer) - Engine size in cc
    • vehicle_power (integer) - Engine power in kW
  • unknown_vehicle (object, optional) - Details if custom vehicle
    • id (string) - Custom vehicle ID
    • type (string) - Vehicle type
    • country (string) - Country code
  • custom_emission_factor_id (string, UUID, optional) - Custom emission factor if specified

Example

Successful Response

Common Errors

400 Bad Request

Cause: Invalid query parameters or date format
Solution: Verify that dates are Unix timestamps (integers) and pagination parameters are positive integers.

403 Forbidden

Cause: Organization ID doesn’t match your API key or user doesn’t belong to organization
Solution: Verify that x-organization-id matches your API key’s organization.

Use Cases

Fleet Dashboard

Display your complete fleet with emissions breakdown:

Filter by Vehicle Type

Get all passenger or freight vehicles:

Filter by Ownership

Get owned vs rented vehicles:

Date Range Query

Get vehicles added within a specific time period:

Pagination

When you have many vehicles, use pagination to retrieve all results:

Special Notes

Known vs Unknown Vehicles

Dcycle maintains a database of known vehicles with specific make, model, and technical specifications. You can:
  • Use known vehicles: Select from database with accurate emission factors based on manufacturer data
  • Create unknown vehicles: Define custom vehicles when your specific model isn’t in our database
When a vehicle has is_known: true, the known_vehicle object contains detailed specifications. When is_known: false, the unknown_vehicle object contains basic type information.

Vehicle Types

Vehicles are classified by usage:
  • passenger: Personal vehicles, company cars, executive vehicles
  • freight: Delivery vans, trucks, commercial vehicles
This classification affects emission calculations and reporting.

Ownership Status

Track vehicle ownership for better fleet management:
  • owned: Vehicles owned by your organization
  • rented: Leased or rented vehicles
This helps distinguish between CAPEX and OPEX emissions in reporting.

Market Segments

For passenger vehicles, market segments help classify vehicle size and emissions:
  • mini - City cars (e.g., Smart ForTwo)
  • supermini - Small cars (e.g., Ford Fiesta)
  • lower_medium - Compact cars (e.g., VW Golf)
  • upper_medium - Mid-size cars (e.g., BMW 3 Series)
  • executive - Large cars (e.g., BMW 5 Series)
  • luxury - Premium cars (e.g., Mercedes S-Class)
  • sports - Sports cars
  • dual_purpose_4x4 - SUVs and 4x4 vehicles
  • mpv - Multi-purpose vehicles (minivans)

CO2e Field

The co2e field represents the total carbon footprint of the vehicle calculated from all fuel consumption records. A value of 0.0 means either:
  • No consumption records have been registered yet
  • All consumptions have zero emissions
  • Calculations are pending

Vehicle Status

Vehicles can have three statuses:
  • active: Vehicle is currently in use
  • archived: Vehicle removed from fleet but data retained for historical reporting
  • error: Vehicle has validation or processing errors (check error_messages field)

Bulk Upload Vehicles

Upload multiple vehicles via CSV

List Facilities

View your facilities

Create Invoice

Add fuel consumption data

Authentication

Learn about API authentication