Skip to main content
PUT
/
loans
/
{id}
Update loan
curl --request PUT \
  --url https://lms.tausi.africa/v1/loans/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "borrower_id": 123,
  "loan_id": 123,
  "loan_type": "<string>",
  "products": [
    {
      "stock_id": 123,
      "quantity": 123,
      "price": 123
    }
  ],
  "principal_amount": 123,
  "released_date": "<string>",
  "due_date": "<string>",
  "duration": 123,
  "duration_period": "<string>",
  "description": "<string>"
}
'
{
  "item": {
    "borrower_id": 123,
    "loan_id": 123,
    "principal_amount": 123,
    "released_date": "<string>",
    "due_date": "<string>",
    "duration": 123,
    "duration_period": "<string>",
    "created_at": "2023-11-07T05:31:56Z",
    "updated_at": "2023-11-07T05:31:56Z",
    "loan_type": "<string>",
    "products": [
      {
        "stock_id": 123,
        "quantity": 123,
        "price": 123
      }
    ],
    "description": "<string>"
  },
  "success": true
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
integer<int64>
required

Body

application/json
borrower_id
integer<int64>
loan_id
integer<int64>
loan_type
string
products
object[]
principal_amount
number<float>
released_date
string
due_date
string
duration
integer
duration_period
string
description
string

Response

Loan updated successfully.

item
object
required
success
boolean
required
Example:

true