curl --request POST \
--url https://tars.loopscale.com/v1/markets/creditbook/repay \
--header 'Content-Type: application/json' \
--data '{
"loan": "<string>",
"collateralWithdrawalParams": [
{
"amount": 123,
"collateralMint": "<string>"
}
],
"repayParams": [
{
"amount": 123,
"ledgerIndex": 123,
"repayAll": true
}
],
"cpiIxs": [
{
"programId": "<string>",
"accounts": [
{
"pubkey": "<string>",
"isSigner": true,
"isWritable": true
}
],
"data": "<string>"
}
],
"cpiLuts": [
"<string>"
],
"cpiSigners": [
"<string>"
]
}'
{
"message": "<string>",
"signatures": [
{
"publicKey": "<string>",
"signature": "<string>"
}
]
}
Partially or fully repay an active loan. Allows for the withdrawal of collateral for optional use in CPIs before repayment.
curl --request POST \
--url https://tars.loopscale.com/v1/markets/creditbook/repay \
--header 'Content-Type: application/json' \
--data '{
"loan": "<string>",
"collateralWithdrawalParams": [
{
"amount": 123,
"collateralMint": "<string>"
}
],
"repayParams": [
{
"amount": 123,
"ledgerIndex": 123,
"repayAll": true
}
],
"cpiIxs": [
{
"programId": "<string>",
"accounts": [
{
"pubkey": "<string>",
"isSigner": true,
"isWritable": true
}
],
"data": "<string>"
}
],
"cpiLuts": [
"<string>"
],
"cpiSigners": [
"<string>"
]
}'
{
"message": "<string>",
"signatures": [
{
"publicKey": "<string>",
"signature": "<string>"
}
]
}
Serialized transaction message and signatures
The response is of type object
.