Webhooks

The ekko Climate API sends webhook notifications when specific events occur on the ImpactPay product. This lets you track payments and reversals in real time without polling the API.

🔄

This page reflects the current API behaviour. Some details may change as v3 is finalised.

Two events are currently supported: IMPACT_PAYMENT and IMPACT_PAYMENT_REVERSAL.

Webhook events

  • IMPACT_PAYMENT: sent when a payment is successfully processed through ImpactPay.
  • IMPACT_PAYMENT_REVERSAL: sent when a previously processed payment is reversed, for example voided or refunded.

Webhook payload

FieldTypeDescription
footprintIdStringReference for the ImpactPay calculation, returned during the impact calculation
organisationIdStringIdentifier for the organisation associated with the payment
brandIdStringIdentifier for the brand associated with the payment
productIdStringIdentifier for the product associated with the payment
customerIdStringIdentifier for the consumer making the payment, as provided during the ImpactPay API call
eventTypeStringEither IMPACT_PAYMENT or IMPACT_PAYMENT_REVERSAL
timestampStringISO 8601 timestamp indicating when the event occurred
paymentObjectDetails about the payment
payment.amountNumberPayment amount in whole units of currency
payment.currencyCodeStringISO currency code for the transaction (e.g. GBP)
payment.serviceFeeNumberService fee included in the payment
carbonObjectCarbon footprint details for the transaction
carbon.unitStringUnit of carbon measurement (e.g. grams)
carbon.quoteNumberOriginal carbon footprint quote for the transaction
carbon.compensatedNumberAmount of carbon the consumer chose to address through credits

Example payloads

IMPACT_PAYMENT

{
  "footprintId": "15372bb6-c7ce-41bf-bb81-e9553de19158",
  "organisationId": "9e1d3a52-0e3d-4a9f-8b6e-1c2d3e4f5a6b",
  "brandId": "e06e3f32-d649-4e4b-a122-99af6f7ff272",
  "productId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
  "customerId": "ef10143b-2d5c-4b44-96e9-93497a5f6a55",
  "eventType": "IMPACT_PAYMENT",
  "timestamp": "2024-10-30T11:18:25.601Z",
  "payment": {
    "amount": 20,
    "currencyCode": "GBP",
    "serviceFee": 1.68
  },
  "carbon": {
    "unit": "grams",
    "quote": 100000,
    "compensated": 20000
  }
}

organisationId identifies which organisation the payment belongs to. carbon.quote is the full estimated footprint for the transaction. carbon.compensated is the portion the consumer chose to address.