From c73eeb907d2a8bfe7885f293ec7c575072e42f36 Mon Sep 17 00:00:00 2001 From: zemion Date: Sat, 23 May 2026 14:53:23 +0200 Subject: [PATCH] nex providers --- README.md | 11 +- providers.xml | 291 ++++++++++++++++++ providers/carboninterface/carboninterface.xml | 50 +++ providers/carbontracer/carbontracer.xml | 71 +++++ providers/climatiq/climatiq.xml | 54 ++++ providers/ibm_eis/ibm_eis.xml | 70 +++++ providers/travelco2/travelco2.xml | 62 ++++ scheme.json | 163 +++++----- 8 files changed, 676 insertions(+), 96 deletions(-) create mode 100644 providers/carboninterface/carboninterface.xml create mode 100644 providers/carbontracer/carbontracer.xml create mode 100644 providers/climatiq/climatiq.xml create mode 100644 providers/ibm_eis/ibm_eis.xml create mode 100644 providers/travelco2/travelco2.xml diff --git a/README.md b/README.md index d50053f..d3b77a6 100644 --- a/README.md +++ b/README.md @@ -69,11 +69,18 @@ The specification is expected to support provider capability discovery instead o | Google Travel Impact Model (various versions) | ✅ | ❌ | ❌ | ❌ | ❌ | | myclimate Flight Calculator V1 & V2 | ✅ | ❌ | ❌ | ❌ | ❌ | | myclimate Bulk Flight Calculator | ✅ | ❌ | ❌ | ❌ | ❌ | -| GoClimate Flight Footprint | ✅ | ✅ | ✅ | ✅ | ❌ | | C-Level Carbon Balance API | ✅ | ❌ | ❌ | ❌ | ❌ | | KlimaLink API | ✅ | ❌ | ❌ | ❌ | ❌ | -| KlimAPI Calculation & Compensation API (v1 & v2) | ✅ | ❌ | ❌ | ❌ | ❌ | +| KlimAPI Calculation & Compensation API (v1 & v2) | ✅ | ✅ | ✅ | ❌ | ❌ | | calco2la.to | ✅ | ✅ | ✅ | ✅ | ✅ | +| GoClimate Flight Footprint | ✅ | ✅ | ✅ | ✅ | ❌ | +| Climatiq | ✅ | ✅ | ✅ | ❌ | ❌ | +| Carbon Interface | ✅ | ❌ | ❌ | ❌ | ❌ | +| TravelCO2 | ✅ | ❌ | ❌ | ❌ | ❌ | +| Sustainable Travel International (STI) | ✅ | ❌ | ❌ | ❌ | ❌ | +| CarbonTracer (Uni Graz) | ✅ | ❌ | ❌ | ❌ | ❌ | +| IBM Environmental Intelligence Suite (EIS) | ✅ | ❌ | ❌ | ❌ | ❌ | + ## License diff --git a/providers.xml b/providers.xml index e351dc5..1ab9079 100644 --- a/providers.xml +++ b/providers.xml @@ -156,6 +156,121 @@ + + Carbon Interface + https://www.carboninterface.com/api/v1 + + CARBONINTERFACE_API_KEY + + + + + + { + "type": "flight", + "passengers": ${request.passengers}, + "legs": [ + #for leg in request.legs + { + "departure_airport": "${leg.origin_iata}", + "destination_airport": "${leg.destination_iata}" + }#sep, + #end + ] + } + + + + + + + + + + + + + + + + + + + + + + + + + + + CarbonTracer Uni Graz + https://api.carbontracer.uni-graz.at + + CARBONTRACER_API_KEY + apikey + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + C-Level Carbon Balance API https://api.c-level.earth @@ -205,6 +320,57 @@ + + Climatiq Travel v1-preview3 + https://preview.api.climatiq.io + + CLIMATIQ_API_KEY + + + + + + { + "travel_mode": "air", + "origin": { + "iata": "${request.legs[0].origin_iata}" + }, + "destination": { + "iata": "${request.legs[0].destination_iata}" + }, + "year": ${request.vendor_options.climatiq_year}, + "distance_km": ${request.legs[0].distance_km}, + "air_details": ${request.vendor_options.climatiq_air_details} + } + + + + + + + + + + + + + + + + + + + + + + + + + + + + + GoClimate Flight Footprint https://api.goclimate.com @@ -289,6 +455,72 @@ + + IBM Environmental Intelligence Suite - Carbon Accounting Transport + https://foundation.agtech.ibm.com/v2/carbon + + IBM_EIS_BEARER_TOKEN + + + + + + { + "customID": { + "id": "${request.reference}" + }, + "onBehalfOfClient": { + "companyId": "${request.vendor_options.ibm_company_id}", + "companyName": "${request.vendor_options.ibm_company_name}" + }, + "organisation": { + "departmentId": "${request.vendor_options.ibm_department_id}", + "departmentName": "${request.vendor_options.ibm_department_name}" + }, + "requestType": "${request.vendor_options.ibm_request_type}", + "location": { + "country": "${request.vendor_options.ibm_country}", + "stateProvince": "${request.vendor_options.ibm_state_province}", + "zipPostCode": "${request.vendor_options.ibm_zip_post_code}", + "city": "${request.vendor_options.ibm_city}" + }, + "site": { + "siteId": "${request.vendor_options.ibm_site_id}", + "siteName": "${request.vendor_options.ibm_site_name}", + "buildingId": "${request.vendor_options.ibm_building_id}", + "buildingName": "${request.vendor_options.ibm_building_name}" + }, + "timePeriod": { + "year": ${request.vendor_options.ibm_year}, + "month": ${request.vendor_options.ibm_month} + }, + "activityData": { + "typeOfActivityData": "Passenger distance", + "vehicleType": "${request.vendor_options.ibm_vehicle_type}", + "distanceTravelled": "${request.legs[0].distance_km}", + "numberOfPassengers": ${request.passengers}, + "unitOfMeasurement": "passenger kilometer", + "fuelUsed": "", + "fuelAmount": "", + "unitOfFuelAmount": "" + } + } + + + + + + + + + + + + + + + + KlimaLink API https://api.dev.klimalink.org @@ -692,4 +924,63 @@ + + TravelCO2 Transport API + https://travelco2.com + + TRAVELCO2_API_KEY + + + + + +
+
+ + + { + "vehicle": { + "type": "${request.vendor_options.travelco2_vehicle_type}", + "fuel": { + "type": "${request.vendor_options.travelco2_fuel_type}" + } + }, + "distance": ${request.legs[0].distance_m}, + "people": ${request.passengers}, + "language": "${request.vendor_options.travelco2_language}" + } + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/providers/carboninterface/carboninterface.xml b/providers/carboninterface/carboninterface.xml new file mode 100644 index 0000000..631cff2 --- /dev/null +++ b/providers/carboninterface/carboninterface.xml @@ -0,0 +1,50 @@ + + + + Carbon Interface + https://www.carboninterface.com/api/v1 + + CARBONINTERFACE_API_KEY + + + + + + { + "type": "flight", + "passengers": ${request.passengers}, + "legs": [ + #for leg in request.legs + { + "departure_airport": "${leg.origin_iata}", + "destination_airport": "${leg.destination_iata}" + }#sep, + #end + ] + } + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/providers/carbontracer/carbontracer.xml b/providers/carbontracer/carbontracer.xml new file mode 100644 index 0000000..6b64e5c --- /dev/null +++ b/providers/carbontracer/carbontracer.xml @@ -0,0 +1,71 @@ + + + + CarbonTracer Uni Graz + https://api.carbontracer.uni-graz.at + + CARBONTRACER_API_KEY + apikey + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/providers/climatiq/climatiq.xml b/providers/climatiq/climatiq.xml new file mode 100644 index 0000000..35c5bd4 --- /dev/null +++ b/providers/climatiq/climatiq.xml @@ -0,0 +1,54 @@ + + + + Climatiq Travel v1-preview3 + https://preview.api.climatiq.io + + CLIMATIQ_API_KEY + + + + + + { + "travel_mode": "air", + "origin": { + "iata": "${request.legs[0].origin_iata}" + }, + "destination": { + "iata": "${request.legs[0].destination_iata}" + }, + "year": ${request.vendor_options.climatiq_year}, + "distance_km": ${request.legs[0].distance_km}, + "air_details": ${request.vendor_options.climatiq_air_details} + } + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/providers/ibm_eis/ibm_eis.xml b/providers/ibm_eis/ibm_eis.xml new file mode 100644 index 0000000..b14a1e0 --- /dev/null +++ b/providers/ibm_eis/ibm_eis.xml @@ -0,0 +1,70 @@ + + + + IBM Environmental Intelligence Suite - Carbon Accounting Transport + https://foundation.agtech.ibm.com/v2/carbon + + IBM_EIS_BEARER_TOKEN + + + + + + { + "customID": { + "id": "${request.reference}" + }, + "onBehalfOfClient": { + "companyId": "${request.vendor_options.ibm_company_id}", + "companyName": "${request.vendor_options.ibm_company_name}" + }, + "organisation": { + "departmentId": "${request.vendor_options.ibm_department_id}", + "departmentName": "${request.vendor_options.ibm_department_name}" + }, + "requestType": "${request.vendor_options.ibm_request_type}", + "location": { + "country": "${request.vendor_options.ibm_country}", + "stateProvince": "${request.vendor_options.ibm_state_province}", + "zipPostCode": "${request.vendor_options.ibm_zip_post_code}", + "city": "${request.vendor_options.ibm_city}" + }, + "site": { + "siteId": "${request.vendor_options.ibm_site_id}", + "siteName": "${request.vendor_options.ibm_site_name}", + "buildingId": "${request.vendor_options.ibm_building_id}", + "buildingName": "${request.vendor_options.ibm_building_name}" + }, + "timePeriod": { + "year": ${request.vendor_options.ibm_year}, + "month": ${request.vendor_options.ibm_month} + }, + "activityData": { + "typeOfActivityData": "Passenger distance", + "vehicleType": "${request.vendor_options.ibm_vehicle_type}", + "distanceTravelled": "${request.legs[0].distance_km}", + "numberOfPassengers": ${request.passengers}, + "unitOfMeasurement": "passenger kilometer", + "fuelUsed": "", + "fuelAmount": "", + "unitOfFuelAmount": "" + } + } + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/providers/travelco2/travelco2.xml b/providers/travelco2/travelco2.xml new file mode 100644 index 0000000..a466197 --- /dev/null +++ b/providers/travelco2/travelco2.xml @@ -0,0 +1,62 @@ + + + + TravelCO2 Transport API + https://travelco2.com + + TRAVELCO2_API_KEY + + + + + +
+
+ + + { + "vehicle": { + "type": "${request.vendor_options.travelco2_vehicle_type}", + "fuel": { + "type": "${request.vendor_options.travelco2_fuel_type}" + } + }, + "distance": ${request.legs[0].distance_m}, + "people": ${request.passengers}, + "language": "${request.vendor_options.travelco2_language}" + } + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/scheme.json b/scheme.json index 3d8e342..c115e0f 100644 --- a/scheme.json +++ b/scheme.json @@ -1,76 +1,21 @@ { - "FlightLeg": { - "origin_iata": "string", - "destination_iata": "string", - "departure_time": "optional ISO-8601 datetime", - "marketing_carrier": "optional string", - "operating_carrier": "optional string", - "flight_number": "optional string" - }, "FlightRequest": { - "legs": ["FlightLeg"], - "cabin_class": "economy | premium_economy | business | first | unknown", - "passengers": "integer >= 1", - "roundtrip": "boolean", - "include_non_co2": "boolean", - "currency": "optional ISO 4217 code" - }, - "EmissionEstimate": { - "co2_kg": "number or null", - "co2e_kg": "number or null", - "non_co2_multiplier": "number or null", - "breakdown": { - "ch4_kg": "number or null", - "n2o_kg": "number or null" - }, - "methodology": { - "method_name": "string or null", - "method_version": "string or null", - "dataset_version": "string or null", - "vendor": "string or null", - "standard": "string or null", - "documentation_url": "string or null" - }, - "vendor_raw": "opaque vendor-specific JSON/XML" - }, - "AirportSearchRequest": { - "query": "string", - "limit": "optional integer", - "country_filter": "optional ISO 3166 code", - "languages": ["optional ISO 639 code"] - }, - "AirportInfo": { - "iata_code": "string", - "icao_code": "string", - "name": "string", - "localized_name": ["LocalizedString"], - "country": "ISO 3166 code", - "continent": "string", - "latitude": "double", - "longitude": "double" - }, - "LocalizedString": { - "lang": "ISO 639 code", - "name": "string" - } -} - -{ - "FlightCalculationRequest": { "api_key": "optional string", - "provider": "optional string", - "operation": "optional string", + "provider": "string", + "operation": "string", + "calculationRequest": "FlightCalculationRequest" + }, + "FlightCalculationRequest": { "departure_date": "optional ISO-8601 date", "rfi": "optional number", "price_per_ton": "optional number", - "currency": "optional ISO 4217 code", "roundtrip": "optional boolean", "passengers": "optional integer >= 1", "cabin_class": "economy | premium_economy | business | first | unknown", "calculation_method": "optional string", "reference": "optional string", "legs": ["FlightLeg"], - "iata_path": ["string"], + "include_non_co2": "boolean", "currencies": ["optional ISO 4217 code"], "vendor_options": "object" }, @@ -81,7 +26,6 @@ "destination_iata": "optional string", "origin": "optional LocationRef", "destination": "optional LocationRef", - "departure_date": "optional ISO-8601 date", "departure_time": "optional ISO-8601 datetime", "flight_number": "optional string", "marketing_carrier": "optional string", @@ -96,7 +40,7 @@ "distance_km": "optional number", "vendor_options": "object" }, - "EmissionCalculationResult": { + "FlightCalculationResult": { "provider": "string", "domain": "string", "operation": "string", @@ -149,14 +93,57 @@ "EmissionAmount": { "co2_kg": "number or null", "co2e_kg": "number or null", - "co2e_tonnes": "number or null", + "non_co2_multiplier": "number or null", + "breakdown": { + "ch4_kg": "number or null", + "n2o_kg": "number or null" + }, "wtw_kg": "number or null", "ttw_kg": "number or null", "wtt_kg": "number or null", - "non_co2_multiplier": "number or null", "unit": "kg | tonnes | grams | null", - "per": "request | passenger | segment | null" + "per": "request | passenger | segment | null", + "vendor_raw": "opaque vendor-specific JSON/XML" }, + "MethodologyMeta": { + "method_name": "string or null", + "method_version": "string or null", + "dataset_version": "string or null", + "vendor": "string or null", + "standard": "string or null", + "documentation_url": "string or null", + "non_co2_treatment": "none | included | partial | unknown" + }, + + "AirportRequest": { + "api_key": "optional string", + "provider": "string", + "operation": "string", + "calculationRequest": "AirportSearchRequest" + }, + "AirportSearchRequest": { + "query": "string", + "limit": "optional integer", + "country_filter": "optional ISO 3166 code", + "languages": ["optional ISO 639 code"] + }, + "AirportInfo": { + "iata_code": "string", + "icao_code": "string", + "name": "string", + "localized_name": ["LocalizedString"], + "country": "ISO 3166 code", + "continent": "string", + "latitude": "double", + "longitude": "double" + }, + "LocalizedString": { + "lang": "ISO 639 code", + "name": "string" + } +} + +{ "CabinClassEmissionSet": { "economy_kg": "number or null", "premium_economy_kg": "number or null", @@ -183,15 +170,7 @@ "id": "string or null", "expires_at": "ISO-8601 datetime or null" }, - "MethodologyMeta": { - "method_name": "string or null", - "method_version": "string or null", - "dataset_version": "string or null", - "vendor": "string or null", - "standard": "string or null", - "documentation_url": "string or null", - "non_co2_treatment": "none | included | partial | unknown" - }, + "ProviderError": { "code": "string or null", "message": "string", @@ -209,24 +188,20 @@ "lon": "number or null", "coord": "string or null" }, - "AirportSearchRequest": { - "query": "string", - "limit": "optional integer", - "country_filter": "optional ISO 3166 code", - "languages": ["optional ISO 639 code"] - }, - "AirportInfo": { - "iata_code": "string", - "icao_code": "string", - "name": "string", - "localized_name": ["LocalizedString"], - "country": "ISO 3166 code", - "continent": "string", - "latitude": "double", - "longitude": "double" - }, - "LocalizedString": { - "lang": "ISO 639 code", - "name": "string" + +} + +{ + "FlightCalculationRequest.vendor_options": { + "climatiq_year": "integer", + "climatiq_air_details": "object", + "carbontracer_type": "flight-economy | flight-business | flight-firstclass", + "travelco2_vehicle_key": "flight-regular-economy | flight-regular-business | ...", + "travelco2_fuel_key": "jetfuel | bio-fuel", + "ibm_request_type": "ACTUAL | SIMULATED", + "ibm_vehicle_type": "string", + "ibm_country": "string", + "ibm_year": "integer", + "ibm_month": "integer" } } \ No newline at end of file