The payload sent to your web-hook 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 Transfer events broadcasted by Torus Mara:
Notifications
- payment_received : This web-hook is sent to confirm receipt of payment made by the fintech partner.
- successful_transfer : This web-hook is sent for each transfer Torus Mara does to the individual beneficiaries.
Sample JSON body for each event
{
"id": "97f54f43-67d0-4bce-9b4c-54a9bb0d4dd9",
"event": "payment_received",
"resource_type": "transfer",
"data": {
"id": "97f54f43-67d0-4bce-9b4c-54a9bb0d4dd9",
"status": "processing",
"batch_date": [
"2022-07-26 00:00:00 +0000 UTC"
],
"transaction_amount": 3055552.5,
"batch_amount": 3045542.5,
"currency": "NGN",
"initiated_at": "2022-09-01T19:13:02.378284Z",
"completed_at": "0001-01-01T00:00:00Z",
"transaction_type": "transfer"
}
}
{
"id": "8ac337f9-43f8-4bb5-8431-608fbd159318",
"event": "successful_transfer",
"resource_type": "transfer",
"data": {
"id": "8ac337f9-43f8-4bb5-8431-608fbd159318",
"customerID": "62fa5415-d7c0-4648-8e08-600a90bc95c9",
"amount": 5000,
"currency": "USD",
"destination": {
"bankDetails": {
"city": "",
"country": "US",
"bankName": "213000",
"district": "",
"swiftCode": "",
"bankBranch": "",
"isWithinUS": "no",
"postalCode": "",
"accountName": "",
"bankAddress": "",
"accountNumber": "1000000",
"routingNumber": "12345"
},
"personalDetails": {
"city": "",
"name": "Kehinde ODETOLA",
"address": "egbatedo street, akowonjo",
"country": "US",
"district": "",
"postalCode": ""
},
"intermediaryBank": null
},
"note": "Some notes here. This field is optional",
"reason": "this field is compulsory and cannot be less than 5 characters",
"createdAt": "2022-07-26T13:32:34.374322+01:00",
"completedAt": {
"Time": "2022-09-01T19:59:42.694784625+01:00",
"Valid": true
},
"updatedAt": {
"Time": "2022-09-01T19:59:42.694784459+01:00",
"Valid": true
},
"batchDate": "2022-07-26T00:00:00Z",
"status": "completed",
"reference": "ref3",
"cancelReason": null,
"type": ""
}
}