Webhooks and Callbacks
The server-to-server callbacks from Pandascrow and Paystack, and the redirect callbacks from Google.
Providers call these routes; clients never do. They do not use bearer tokens. Each one proves where it came from with a signature or a signed state value.
| Route | Caller | Verified by |
|---|---|---|
POST /webhooks/pandascrow | Pandascrow | X-Pandascrow-Signature: hex HMAC-SHA256 of the raw body |
POST /api/v1/transaction/webhook/paystack | Paystack | x-paystack-signature: hex HMAC-SHA512 of the body |
GET /api/v1/calendar/google/callback | The user's browser, sent by Google | A signed state value issued 10 minutes earlier |
GET /api/v1/auth/google/callback | The web app, after Google's redirect | The one-time code from Google |
Pandascrow
Mounted on the server root, outside /api/v1. The raw request bytes are kept for the signature check, and an optional X-Pandascrow-Timestamp must be within 5 minutes of the server's clock.
| Event | Effect |
|---|---|
escrow.paid | Escrow pending to funded. Buyer, seller and agent are notified. |
escrow.completed | Escrow to completed, then the seller, agent and platform payouts run in the background. |
escrow.dispute.opened, escrow.disputed | Escrow to disputed. Parties are notified once. |
escrow.payout.completed | Records whether the release to the seller's bank succeeded. A failed bank payout returns the money to the seller's wallet. |
milestone.paid | Escrow to funded. |
| Anything else | Acknowledged and ignored. |
Every verified delivery is answered with { "status": true }, because Pandascrow treats any other body as a failure and retries. A processing error answers 500 so that it retries.
Full details: Pandascrow webhook.
Paystack
Only charge.success is handled. The metadata.type set when the payment was started decides what it updates:
metadata.type | Effect |
|---|---|
inspection | Marks the inspection paid and scheduled, the same as the verify endpoint. Safe to receive twice. |
PROPERTY_BOOKING | Marks the tenant's booking for the property confirmed. |
A bad signature answers 401 with the plain-text body Invalid signature. Success answers { "received": true }.
Booking payments via Paystack are fragile
The PROPERTY_BOOKING branch confirms whichever booking of that tenant on that property it finds first, does not save the payment reference, and creates a bare booking if none exists. It also sends no notification. See the endpoint page before relying on it.
Google Calendar
- The client calls
GET /api/v1/calendar/google/url(bearer token) and sends the user to the returned Google consent URL. - Google redirects the browser to
GET /api/v1/calendar/google/callbackwith acodeand the signedstate. - The server stores the user's calendar access, adds their paid upcoming inspections to the calendar, and redirects to the web app with
?calendar=connected, or?calendar=errorif anything failed.
GET /api/v1/calendar/google/status tells the app whether the calendar is connected, and DELETE /api/v1/calendar/google disconnects it.
HomeLink Hub