Vehicle Fuels API
The Vehicle Fuels API allows you to retrieve and manage fuel types available for vehicles in your organization. Each fuel type includes associated emission factors and units of measurement for accurate CO2e calculations.Reference Data: This API provides reference data for fuel types used when creating or updating vehicles. Fuel types define how emissions are calculated based on vehicle usage.
Key Features
- Fuel Type Catalog: Browse all available fuel types for your vehicles
- Emission Factors: View standardized emission factors per fuel type
- Unit Management: Access fuel units and conversion factors
- Country-Specific: Get fuel data specific to different countries
- Reference Data: Use IDs from this API when creating vehicles
Authentication
All endpoints require authentication using either:- API Key: Include in
Authorizationheader asBearer {API_KEY} - JWT Token: Include in
Authorizationheader asBearer {JWT_TOKEN}
Headers
All requests should include:Bearer token for authenticationFormat:
Bearer {API_KEY} or Bearer {JWT_TOKEN}Available Endpoints
Fuel Types
Common fuel types include:| Fuel Type | Description | Emission Factor (kg CO2e/unit) |
|---|---|---|
| Petrol | Gasoline/benzine fuel | ~2.31 per liter |
| Diesel | Diesel fuel | ~2.68 per liter |
| Electric | Electric battery powered | ~0.0 per kWh (upstream) |
| Hybrid | Petrol-electric hybrid | ~1.5 per liter |
| LPG | Liquified petroleum gas | ~1.54 per kg |
| Natural Gas | Compressed natural gas | ~2.04 per kg |
| Hydrogen | Hydrogen fuel cell | ~0.0 per kg (production dependent) |
Fuel Units
Fuel can be measured in various units:| Unit | Type | Description |
|---|---|---|
| liter | Volume | Standard fuel measurement for liquid fuels |
| kg | Mass | Used for gaseous and solid fuels |
| kWh | Energy | Used for electric vehicles |
| gallon | Volume | US/Imperial fuel measurement |
| m³ | Volume | Cubic meters for gaseous fuels |
Fuel Object Structure
Workflow
Using Fuel Types with Vehicles
- List available fuels using
GET /v1/vehicle-fuels - Select a fuel type for your vehicle based on:
- Fuel type (petrol, diesel, electric, etc.)
- Country (emission factors vary by region)
- Use the fuel ID when creating or updating vehicles with
vehicle_fuel_id
Common Usage Patterns
Error Handling
Common HTTP Status Codes
| Status | Meaning | Solution |
|---|---|---|
| 200 | Success | - |
| 401 | Unauthorized | Verify API key or JWT token |
| 500 | Server Error | Contact support if persists |
Error Response Format
Use Cases
Build Fuel Selection UI
Display available fuels in your application:Compare Emissions by Fuel Type
Analyze how fuel type affects emissions:Related Documentation
Create Vehicle
Create vehicles with specific fuel types
List Vehicles
View vehicles and their fuel assignments
Unknown Vehicles
Browse vehicle type classifications
Vehicles API
Manage your vehicle fleet
Rate Limiting
API requests are subject to rate limiting. Include rate limit information from response headers:X-RateLimit-Limit: Maximum requests per minuteX-RateLimit-Remaining: Requests remainingX-RateLimit-Reset: Unix timestamp when limit resets

