Appearance
Get a batch's fee quote​
GET
/v2/payments/bulk-withdrawals/batches/{id}/fee-quote
Requires DISBURSEMENTS_READ, granted by PAYMENTS_READ or DISBURSEMENTS_WRITE (bundles)
Returns the fee for the batch's withdrawals that are still pending or, once none are pending, the fee that was charged. Unlike GET /v2/payments/bulk-withdrawals/batches/{id}, this returns an error rather than null when the fee can't be quoted.
Parameters​
Path Parameters
id*
Batch ID.
Type
Requiredstring
Example
"5b9a3c1e-2f4d-4a7b-9c8e-1d2f3a4b5c6d"Format
"uuid"Responses​
OK
application/json
JSON
{
"fee": "25.00",
"currency": "ZAR",
"withdrawalCount": 2,
"grossTotal": "20501.00",
"requiredTotal": "20526.00",
"feeGroups": null
}
Samples​
Errors
| HTTP | Error | When |
|---|---|---|
| 400 | BAD_REQUEST | A query parameter or field is invalid. |
| 400 | -11INVALID_REQUEST | The batch ID isn't a valid UUID. |
| 403 | -16098PAYMENTS_USER_ACCESS_NOT_CONFIGURED | Payments haven't been set up for your business yet. |
| 404 | NOT_FOUND | No batch with this ID exists on your account. |
| 500 | INTERNAL_ERROR | Unexpected error in the payments service. |
| 502 | -16097EXCHANGE_API_ERROR | The payments service failed to process the request. |
| 502 | EXCHANGE_API_ERROR | The payments service couldn't complete the request. Try again later. |
| 503 | -16099PAYMENTS_BACKEND_PROXY_DISABLED | Payments endpoints are temporarily unavailable. |
Plus the errors common to all signed endpoints.