Skip to main content
POST
/
v1
/
loans
/
{loan_id}
/
repayments
/
refund
Issue a refund
curl --request POST \
  --url https://api-dev.bsa.ai/v1/loans/{loan_id}/repayments/refund \
  --header 'Authorization: Bearer <token>'

Documentation Index

Fetch the complete documentation index at: https://docs.api.bsa.ai/llms.txt

Use this file to discover all available pages before exploring further.

Records a refund-by-cash transaction. Use this when a loan was overpaid (e.g. a duplicate repayment was applied) and the borrower needs to be refunded the excess.

Path parameters

loan_id
string
required

Request body

See the common repayment body. transactionAmount must not exceed the loan’s overpayment balance.

Example

curl -sf -X POST "$BASE/v1/loans/501/repayments/refund" \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "transactionDate": "2026-10-05",
    "transactionAmount": 50,
    "note": "Refund duplicate repayment 7821"
  }'

Response

200 OK returns the repayment object.

Errors

CodeWhen
not_foundNo loan with that ID
abortedAmount exceeds available overpayment balance