Skip to main content
POST
/
lending-stocks
/
api
/
positions
/
{marketId}
/
add-collateral
curl -X POST "https://api.trusset.org/lending-stocks/api/positions/{marketId}/add-collateral" \
  -H "X-API-Key: trusset_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{"loanId": 5, "amount": "25", "useRelayer": true}'
{
  "success": true,
  "data": { "txHash": "0xabc...def", "loanId": 5, "amount": "25" }
}

Documentation Index

Fetch the complete documentation index at: https://docs.trusset.org/llms.txt

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

Deposits additional stock tokens into an active loan to improve its health factor.

Path Parameters

marketId
string
required
Market ID.

Body Parameters

loanId
integer
required
On-chain loan ID.
amount
string
required
Stock tokens to add (e.g. "25").
useRelayer
boolean
default:"false"
Execute via relayer or return calldata.
curl -X POST "https://api.trusset.org/lending-stocks/api/positions/{marketId}/add-collateral" \
  -H "X-API-Key: trusset_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{"loanId": 5, "amount": "25", "useRelayer": true}'
{
  "success": true,
  "data": { "txHash": "0xabc...def", "loanId": 5, "amount": "25" }
}