Customer Deposit Webhook Update
The deposit webhook for virtual accounts has been updated to include a new field: depositor_details
. This field provides detailed information about the depositor when available.
Details of the Change
New Field Added: depositor_details
has been added to the data object within the deposit webhook payload.
Field Description:
depositor_details: An object containing details about the depositor, including the name, SWIFT code, sort code, bank name, account number, and IBAN.
If the depositor's details are not available, the depositor_details
field will be set to null
Example
Example of the depositor details when populated
{
"name": "John Doe",
"swift_code": "SWIFT1234",
"sort_code": "",
"bank_name": "",
"account_number": "",
"iban": "GB82WEST12345698765432"
}
Before the change
{
"id": "e64488ba-906b-4717-9e33-cd18fa5c8f8b",
"event": "payment",
"resource_type": "deposit",
"data": {
"id": "123456",
"customer_id": "923b2df5-4a89-4ceb-b148-c2e5ac52d04e",
"business_id": "bfa03a8b-7963-432c-870d-1615e1ade10f",
"reference": "842ccb30-2b7b-437e-b991-e1320c3b0fb9",
"currency": "USD",
"amount": 1000.50,
"deposited_amount": 1000.50,
"deposited_currency": "USD",
"channel": "bank_transfer",
"depositor_details": null,
"created_at": "2024-05-22T14:48:00Z",
"status": "completed"
},
"live": false,
"timestamp": 1713521972
}
After the change
{
"id": "e64488ba-906b-4717-9e33-cd18fa5c8f8b",
"event": "payment",
"resource_type": "deposit",
"data": {
"id": "123456",
"customer_id": "923b2df5-4a89-4ceb-b148-c2e5ac52d04e",
"business_id": "bfa03a8b-7963-432c-870d-1615e1ade10f",
"reference": "842ccb30-2b7b-437e-b991-e1320c3b0fb9",
"currency": "GBP",
"amount": 1000.50,
"deposited_amount": 1000.50,
"deposited_currency": "GBP",
"channel": "bank_transfer",
"depositor_details": {
"name": "John Doe",
"swift_code": "SWIFT1234",
"sort_code": "",
"bank_name": "",
"account_number": "",
"iban": "GB82WEST12345698765432"
},
"created_at": "2024-05-22T14:48:00Z",
"status": "completed"
},
"live": false,
"timestamp": 1713521972
}
{
"id": "e64488ba-906b-4717-9e33-cd18fa5c8f8b",
"event": "payment",
"resource_type": "deposit",
"data": {
"id": "123456",
"customer_id": "923b2df5-4a89-4ceb-b148-c2e5ac52d04e",
"business_id": "bfa03a8b-7963-432c-870d-1615e1ade10f",
"reference": "842ccb30-2b7b-437e-b991-e1320c3b0fb9",
"currency": "GBP",
"amount": 1000.50,
"deposited_amount": 1000.50,
"deposited_currency": "GBP",
"channel": "bank_transfer",
"depositor_details": null,
"created_at": "2024-05-22T14:48:00Z",
"status": "completed"
},
"live": false,
"timestamp": 1713521972
}
Impact
Backward Compatibility: This change is backward-compatible. The depositor_details
field will appear as null
for deposits where this information is not available, ensuring no disruptions to existing integrations.
Usage: Developers should update their integrations to handle the new depositor_details
field, especially if they require information about the depositor for further processing or logging.
Action Required
Review and update your webhook handling code to process the new depositor_details
field if required.
Test your integration to ensure it handles both scenarios where depositor_details
is populated and when it is null
.