Webhook Notifications
Overview​
Webhooks allow you to receive real-time notifications about contract events. Instead of polling the API for updates, WePay will send HTTP POST requests to your specified endpoint whenever important events occur.
Key Benefits:
- Real-time Updates: Get notified immediately when events occur
- Reduced API Calls: No need to poll for status changes
- Reliable Delivery: Automatic retries with exponential backoff
- Secure: HMAC-SHA256 signature verification
Webhook Event Types​
WePay sends webhooks for the following events:
| Event Type | Description |
|---|---|
| contract.created | A new contract has been created |
| contract.approved | Contract has been approved by the other party |
| contract.rejected | Contract has been rejected |
| contract.cancelled | Contract has been cancelled |
| payment.completed | Payment has been completed and funds are in escrow |
| contract.delivered | Seller marked the contract as delivered |
| contract.received | Buyer confirmed receipt of delivery |
| contract.released | Funds have been released to the seller |
| contract.disputed | A dispute has been raised on the contract |
| contract.refunded | Contract has been refunded to the buyer |
| contract.completed | Contract has been fully completed |
| webhook.test | Test webhook (sent via /webhooks/test endpoint) |