The payload sent to your webhook URL would have an event property that identifies what the event is about, a resource property identifying the transaction type and the data attribute which would contain the event data.
Below is a list of Virtual account events broadcasted by Oval Finance:
account_allocated_successful : This webhook is sent when a virtual account has been created successfully.
account_allocated_failed : This webhook is sent when a virtual account fails.
Sample JSON body for each event:
{
"id": "f7cf285f-297f-432e-9320-864ebb8c3836",
"event": "account_allocated_successful",
"resource_type": "deposit",
"data": {
"id": "6ba7b810-9dad-11d1-80b4-00c04fd430c8",
"customerID": "6ba7b810-9dad-11d1-80b4-00c04fd430c9",
"businessID": "6ba7b810-9dad-11d1-80b4-00c04fd430c0",
"accountID": "ACC123456",
"accountDetail": {
"iban": "GB29 NWBK 6016 1331 9268 19",
"sortCode": "12-34-56",
"notes": null,
"bankPhone": "",
"reference": "TRANSFER123",
"swiftCode": null,
"bankAddress": "123 Main Street, London, UK",
"accountName": "John Doe",
"accountNumber": "12345678",
"bankName": "National Westminster Bank",
"bankCode": "",
"routingNumber": "",
"beneficiaryAddress": "UK"
},
"reference": "REF123456",
"currency": "EUR",
"createdAt": "2024-02-28T12:00:00Z",
"updatedAt": "2024-02-28T13:30:00Z",
"deletedAt": null
}
}
{
"id": "f7cf285f-297f-432e-9320-864ebb8c3836",
"event": "account_allocated_successful",
"resource_type": "deposit",
"data": {
"request_id": "f7cf285f-297f-432e-9320-864ebb8c3836",
"business_id": "efc285f-297f-432e-9320-232fcc8c5663",
"customer_id": "f4bab8b7-7e9b-479d-ab18-237cdd86795e",
"message": "",
"details": ""
}
}