Skip to main content
POST
/
api
/
calculate
Calculate Flight Emissions
curl --request POST \
  --url https://external.emissions.bnzgreen.io/api/calculate \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <x-api-key>' \
  --header 'x-body-signature: <x-body-signature>' \
  --header 'x-platform-id: <x-platform-id>' \
  --data '
{
  "flights": [
    {
      "origin": "<string>",
      "destination": "<string>",
      "operatingCarrierCode": "<string>",
      "flightNumber": 123,
      "departureDate": {
        "year": 123,
        "month": 123,
        "day": 123
      }
    }
  ]
}
'
[
  {
    "flight": {
      "origin": "<string>",
      "destination": "<string>",
      "operatingCarrierCode": "<string>",
      "flightNumber": 123,
      "departureDate": {
        "year": 123,
        "month": 123,
        "day": 123
      }
    },
    "emissionsGramsPerPax": {
      "first": 123,
      "business": 123,
      "premiumEconomy": 123,
      "economy": 123
    }
  }
]

Headers

x-api-key
string
required

API key for authentication

x-body-signature
string
required

Signature of the request body signed with API secret (private key)

x-platform-id
string
required

Unique identifier for the platform making the request

Body

application/json
flights
object[]
required

List of flights to calculate emissions for

Response

Flight emissions calculation successful

flight
object
emissionsGramsPerPax
object