GET /carbon/calculate
Calculate the CO2 emissions (in kg) for a specific activity and amount. Supports activities like flights, driving, electricity usage, and heating. Provide the activity type and amount (e.g., kilometers driven, kWh consumed). Returns the total CO2 equivalent. Useful for personal carbon footprint trackers, corporate sustainability reporting tools, and environmental awareness apps that help users understand their impact.
activity
required
Activity type
amount
required
Amount
| Name | Required | Default | Description |
|---|---|---|---|
activity |
Yes | - | Activity type |
amount |
Yes | - | Amount |
curl "https://nordapi.ee/api/v1/carbon/calculate?activity=flight_long&amount=5000"
curl "https://nordapi.ee/api/v1/carbon/calculate?activity=flight_long&amount=5000"
curl "https://nordapi.ee/api/v1/carbon/calculate?activity=driving&amount=100"
curl "https://nordapi.ee/api/v1/carbon/calculate?activity=electricity&amount=500"
{
"data": {
"activity": "flight_long",
"amount": 5.0e3,
"co2_kg": 975.0,
"co2_tonnes": 0.975,
"equivalent_driving_km": 5078.1,
"equivalent_trees_year": 44.79,
"name": "Long-haul flight (per km per passenger)",
"unit": "km"
},
"success": true
}