Skip to main content
Webhooks let PCX push event notifications to your server the moment something changes — a payment settles, a virtual account receives a deposit, or a transfer completes. This eliminates the need to poll for status updates.

Register your endpoint

Add your webhook URL to your organization using the Public service:
The response includes a secret_key. Store it securely — PCX uses it to sign every delivery, and it is returned only once at registration. Your endpoint must be reachable over HTTPS. PCX starts delivering events immediately after registration. By default you receive all event types. To subscribe to specific events only, pass an events array at registration or replace the list later with PUT /public/webhooks/events. Fetch the full list of subscribable types from GET /public/webhooks/events/catalogue.

Event payload structure

Every event follows the same envelope:
  • event_object carries the object the event is about; event_object_id and event_object_status lift its identifier and status to the envelope.
  • occurred_at is when the event happened; a timestamp field records when the delivery was sent.
  • A legacy data field duplicates event_object for existing integrations.
Use event_id to deduplicate — it stays the same across retries, and PCX may deliver the same event more than once. Process each event_id exactly once.

Verify the signature

PCX signs every delivery with HMAC-SHA256 using your secret_key. Two signature headers are sent: Deliveries also include X-Event-Type and X-Event-ID headers. Prefer the v2 signature — including the timestamp protects against replay. The timestamp is set per delivery attempt, so also reject timestamps older than a window you choose (for example five minutes). Always compute the HMAC over the exact raw bytes of the request body — do not re-serialize the parsed JSON.
Reject any webhook event where the signature does not match. Never process unverified payloads — they may be spoofed.

Acknowledge receipt

Return a 2xx HTTP status within 30 seconds (the default delivery timeout). PCX does not inspect the response body — any 2xx counts as a successful acknowledgement. If your processing logic takes longer, acknowledge immediately and handle the event asynchronously:

Retry schedule

PCX attempts delivery up to 3 times in quick succession. If all fail, the event is retried on a backoff schedule: Events still failing after 11 total attempts are marked permanently failed. Contact support to redeliver a permanently failed event.

Event types

See Webhooks in Concepts for the payment event payload schema.

Test your integration

Fire a synthetic event at your registered endpoint — signed with your real secret — to verify signature validation and processing end to end:
event_type defaults to virtual_account.deposit_received when omitted. The response reports whether your endpoint acknowledged the delivery.