Skip to content

@lending:healthFactor

Health factor of an account's lending position, 1e18-scaled (below 1e18 the position is liquidatable; uint256.max when the account has no debt). Composes with assertions: assert @lending:healthFactor(@me) >= 1.5e18.

Returns: number

@lending:healthFactor(account adapter?)
NameTypeDescription
accountaddressAccount to inspect
[adapter]lending-adapterLending protocol: AaveV3, Spark or CompoundV3 (default: the best available on the chain)
# Print the health factor (1e18-scaled; below 1e18 is liquidatable)
print "Health factor:" @lending:healthFactor(@me)