curl --location --request GET 'https://api.hub2.io/refunds?fromDate=2023-01-01T00:00:00.000&toDate=2023-01-01T12:00:00.000&page=1&perPage=100' \
--header 'ApiKey: [REDACTED]' \
--header 'MerchantId: [REDACTED]' \
--header 'Environment: sandbox' \
--header 'Content-Type: application/json'
{
"data": [
{
"id": 123,
"status": "successful",
"transactionId": "tr_000000000000000000011",
"amount": 2000,
"currency": "XOF",
"reason": "Customer requested refund",
"paymentMethod": "mobile_money",
"fallbackAllowed": true,
"fallbackUsed": false,
"metadata": {},
"zendeskTicketId": "zd_123456",
"createdAt": "2023-01-01T12:00:00.000Z",
"updatedAt": "2023-01-01T12:30:00.000Z"
},
{
"id": 124,
"status": "pending",
"transactionId": "tr_000000000000000000012",
"amount": 1500,
"currency": "XOF",
"reason": "Merchant initiated refund",
"paymentMethod": "mobile_money",
"fallbackAllowed": true,
"fallbackUsed": false,
"metadata": {},
"zendeskTicketId": "zd_789012",
"createdAt": "2023-01-01T11:30:00.000Z",
"updatedAt": "2023-01-01T11:30:00.000Z"
}
],
"pagination": {
"page": 1,
"perPage": 100,
"total": 2,
"totalPages": 1
}
}
This endpoint allows you to retrieve a list of refunds with filtering and pagination options.
curl --location --request GET 'https://api.hub2.io/refunds?fromDate=2023-01-01T00:00:00.000&toDate=2023-01-01T12:00:00.000&page=1&perPage=100' \
--header 'ApiKey: [REDACTED]' \
--header 'MerchantId: [REDACTED]' \
--header 'Environment: sandbox' \
--header 'Content-Type: application/json'
{
"data": [
{
"id": 123,
"status": "successful",
"transactionId": "tr_000000000000000000011",
"amount": 2000,
"currency": "XOF",
"reason": "Customer requested refund",
"paymentMethod": "mobile_money",
"fallbackAllowed": true,
"fallbackUsed": false,
"metadata": {},
"zendeskTicketId": "zd_123456",
"createdAt": "2023-01-01T12:00:00.000Z",
"updatedAt": "2023-01-01T12:30:00.000Z"
},
{
"id": 124,
"status": "pending",
"transactionId": "tr_000000000000000000012",
"amount": 1500,
"currency": "XOF",
"reason": "Merchant initiated refund",
"paymentMethod": "mobile_money",
"fallbackAllowed": true,
"fallbackUsed": false,
"metadata": {},
"zendeskTicketId": "zd_789012",
"createdAt": "2023-01-01T11:30:00.000Z",
"updatedAt": "2023-01-01T11:30:00.000Z"
}
],
"pagination": {
"page": 1,
"perPage": 100,
"total": 2,
"totalPages": 1
}
}
2023-01-01T00:00:00.000Z
)2023-01-01T12:00:00.000Z
)created
, pending
, pending_manual
, successful
, failed
Show Refund Object
curl --location --request GET 'https://api.hub2.io/refunds?fromDate=2023-01-01T00:00:00.000&toDate=2023-01-01T12:00:00.000&page=1&perPage=100' \
--header 'ApiKey: [REDACTED]' \
--header 'MerchantId: [REDACTED]' \
--header 'Environment: sandbox' \
--header 'Content-Type: application/json'
{
"data": [
{
"id": 123,
"status": "successful",
"transactionId": "tr_000000000000000000011",
"amount": 2000,
"currency": "XOF",
"reason": "Customer requested refund",
"paymentMethod": "mobile_money",
"fallbackAllowed": true,
"fallbackUsed": false,
"metadata": {},
"zendeskTicketId": "zd_123456",
"createdAt": "2023-01-01T12:00:00.000Z",
"updatedAt": "2023-01-01T12:30:00.000Z"
},
{
"id": 124,
"status": "pending",
"transactionId": "tr_000000000000000000012",
"amount": 1500,
"currency": "XOF",
"reason": "Merchant initiated refund",
"paymentMethod": "mobile_money",
"fallbackAllowed": true,
"fallbackUsed": false,
"metadata": {},
"zendeskTicketId": "zd_789012",
"createdAt": "2023-01-01T11:30:00.000Z",
"updatedAt": "2023-01-01T11:30:00.000Z"
}
],
"pagination": {
"page": 1,
"perPage": 100,
"total": 2,
"totalPages": 1
}
}