Docs
Webhooks

Agoo Market partner events

What Agoo Market sends a delivery or inspection partner's endpoint, its envelope and booking events, with an example, and how retries, sending again, tests and secrets work.

PreviewFor developers at Agoo Market's delivery and inspection partners

This is a published preview. Names and fields may still change before general availability; changes will be listed in the changelog.

A delivery or inspection partner of Agoo Market can have its bookings sent to its own system as they happen. The manager of the partner's account keeps up to five endpoints on at once, on agoo.reviews, under Your Account, the business's name, Send bookings to your own system. Send Partner Bookings to Your Own System has the steps.

A partner receives events about its own bookings, and nobody else's. These are separate from an organisation's webhooks: they go only to the partner's endpoints, they aren't in GET /events, and they have their own envelope.

The envelope

Each event is one POST with a JSON body:

{
  "id": "evt_01m6k4d6f8h0k2m4p6r8t0v2xz",
  "type": "market.booking.created",
  "created_at": "2026-12-01T10:15:00Z",
  "livemode": true,
  "data": {
    "object": {
      "id": "01900000-0000-7c86-8000-000000000001",
      "partner_id": "01900000-0000-7c84-8000-000000000001",
      "kind": "delivery",
      "state": "requested",
      "listing_id": "01900000-0000-7c81-8000-000000000001",
      "partner_fee_pesewas": 3500,
      "delivery_address": "12 Example Avenue, Osu, Accra",
      "contact_phone": "+233245550104",
      "created_at": "2026-12-01T10:15:00Z"
    }
  }
}
FieldWhat it is
idThe event's ID (evt_…), also sent as the webhook-id header. The same on every retry and at each of your endpoints.
typemarket.booking.created or market.booking.updated.
created_atWhen the event happened, in UTC.
livemodetrue for a real booking. false while your partner account is set up for testing, and for a test from your page.
data.objectThe booking.

There is no organisation_id: a partner isn't an Agoo organisation.

The booking

FieldWhat it is
idThe booking's ID. Always there.
partner_idYour partner ID. Always there.
kinddelivery or inspection. Always there.
stateWhere the booking is. Always there.
listing_idThe listing it is for, on market.booking.created.
partner_fee_pesewasYour fee in pesewas, on market.booking.created.
delivery_addressWhere to go, when the booking has an address.
contact_phoneThe number to call, when the booking has one.
inspection_report_idThe report you just attached, when state becomes report_ready.
created_at, updated_atWhen it was booked, on market.booking.created, and when it changed, on market.booking.updated.

A field with nothing in it is left out. The address and phone are personal data: keep them only as long as the booking needs them.

market.booking.created comes with state requested. market.booking.updated comes each time the state changes, including when you change it yourself:

stateWhat it means
requestedBooked, and waiting for you.
acceptedYou've taken it.
picked_upYou have the item.
out_for_deliveryIt's on its way to the buyer.
delivered_paidIt's delivered, and the buyer has paid.
remittedThe money has reached the seller.
refused_at_doorThe buyer didn't take it.
in_inspectionYou're inspecting the item.
report_readyThe inspection report is ready.
cancelledIt's off.

Verify the signature

Events are signed like every other Agoo webhook, with the webhook-id, webhook-timestamp and webhook-signature headers and your endpoint's whsec_ secret. Verify signatures has the code to copy. Check the signature against the exact bytes you received, before you parse them.

Each endpoint has its own secret, shown once when you add the endpoint. Rotate secret makes a new one, also shown once, and you choose how long the old one keeps working beside it: up to 24 hours, or not at all.

While both work, webhook-signature holds two signatures with a space between them, one from each secret:

webhook-signature: v1,K5oZfzN95Z9UVu1EsfQmfVNQhnkZ2pj9o9NDN/H/pI4= v1,bm9ldHUjKzFob2VudXRob2VodWUzMjRvdWVvdW9ldQo=

Accept the event if either one matches the secret your server has, as the code in Verify signatures does, and nothing is missed while you change it over. End the old one now stops the old secret early. If a secret has leaked, end it at once when you rotate.

Retries

Return any 2xx within 15 seconds. Anything else is a failed attempt, and Agoo tries again on the same schedule as its other webhooks: eight attempts over about 27 hours.

  • Only the endpoint that failed gets the retry. One that has answered 2xx isn't sent the event again.
  • A retry is the same event. The id and the body don't change, byte for byte. The webhook-timestamp and the signature are new.
  • Handle each event once. An answer can be lost on its way to Agoo, so the same event can still reach you twice. Keep the webhook-id of what you've handled and skip it the next time.
  • Order isn't promised. A retry can arrive after a later change. Compare created_at before you overwrite a booking's state.

Send an event again

If your system lost an event, the manager of the partner's account can have it sent again from your page:

  • Send again, beside a delivery, sends that event to the endpoint it went to.
  • Send what didn't arrive, on an endpoint, sends every event since a time you choose that the endpoint never answered with a 2xx, including those from while it was off. You see how many there are first. Up to 500 go at once, oldest first.

It is the same event: the same webhook-id and the same body, byte for byte, with a new webhook-timestamp and signature. If your server skips a webhook-id it has handled, it skips this one too, so clear what you kept for it before you ask. An event sent again goes out within a minute or so, is retried on the same schedule, and has its own line under Recent Deliveries.

Nothing is sent to an endpoint that is off or removed. Up to 1,000 events can be sent again in an hour.

How long events are kept

Events and their deliveries are kept for 30 days, then deleted. After that an event can't be sent again.

Turn an endpoint off or remove it

Turn off stops an endpoint at once and keeps its secret and its deliveries. New events aren't held for it: after Turn on, use Send what didn't arrive for the ones it missed. Remove deletes the endpoint, its secret and its deliveries for good.

Send a test

Send test on your page sends a sample booking, of a type the endpoint listens for, signed with its real secret and with livemode false. It is sent once and never retried. Recent Deliveries shows what your server answered.

On this page