Skip to main content

Mode analysis (on-chain)

GET 

/v1/data/lending/mode/analysis

Evaluate all mode-switching options for a user. The API fetches the user's current positions and balance data on-chain via multicall — no request body needed.

Output: For each available mode on the specified lender/chain, returns:

  • healthFactor — the hypothetical health factor if the user switches to that mode (null if no debt)
  • supportedAssets — which marketUids are eligible as collateral or for borrowing in that mode
  • canSwitch — whether the switch is safe (health factor > 1 and no incompatible debt)

Mode categories are cached server-side (1 hour TTL). Market configs are cached (3 minute TTL).

The "mode" terminology is the protocol-agnostic generalization of Aave V3's "e-mode" (efficiency mode); other lenders expose analogous category mechanisms.

Plain-text reference — GET /v1/data/lending/mode/analysis

Parameters

ParameterInTypeRequiredDescription
lenderquerystringyesProtocol identifier See the LenderId schema for the full set of accepted values.
chainquerystringyesChain ID
operatorquerystringyesWallet address of the user
accountIdquerystringnoSub-account ID (for multi-subaccount lenders like Init Capital). Defaults to first sub-account.

Response 200

FieldTypeDescription
successTrue
dataobjectInformational payload. null when the endpoint only builds calldata.
actionsnull

Example response

{
"success": true,
"data": {}
}

Request

Responses

Mode analysis results