Huma Institutional
Autotasks
The Huma protocol employs OpenZepplin's Autotasks to perform certain routine processes. There are four types of Autotasks, with each of them supporting a different aspect of the pool operation:
AutoPay Autotask
Fetch all credits with a due date in the next 2 days and the credit state is in
GoodStandingorDelayed.For each credit, if the borrower has enough funds in their wallet to cover the payment amount (
nextDue + totalPastDue), and has approved enough allowance to the pool, callmakePaymenton behalf of the borrower to pay back the pool.
Close Epoch Autotask
Fetch all pools where the current epoch
endTimeis in the past.Call
processYieldForLenderson the junior and senior tranche.Call
closeEpochon the epoch manager contract.Call
investFeesInFirstLossCoveron the pool fee manager contract.Call
payoutYieldon all first loss cover contracts of the pool.
Refresh Credit Autotask
Fetch all credit lines where
nextBillRefreshDateis in the past and credit state is inGoodStandingorDelayed.Call
refreshCrediton the credit manager contract for that borrower.
Start Committed Credit Autotask
Fetch all credit lines where credit state is
Approved, committed amount is greater than 0, and the designated credit start date is in the past.Call
startCommittedCrediton the credit manager contract for that credit.
Submit Redemption Request Autotask
Fetch all pools that has the
autoRedmeptionAfterLockUpsetting enabled.For each pool, fetch all lenders whose deposit lockup period has expired.
Call
addRedemptionRequeston the contract to submit redemption requests for all the shares owned by the lender.
Unless otherwise noted, all Autotasks run every 5 minutes. For access control, Autotasks will call contracts using the Sentinel service account wallet.
Last updated