Skip to main content

Documentation Index

Fetch the complete documentation index at: https://kamino.com/docs/llms.txt

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

This is the canonical reference for LendingMarket — the on-chain struct that holds market-level settings. Field names below use snake_case as they appear in the JSON returned by download-lending-market-config (which mirrors the on-chain Rust struct directly). For guidance on which fields to set, see Market settings and the topic-specific guides linked below.

Identity and naming

FieldTypeDescription
versionu64Program version, fixed at init
bump_seedu64PDA bump seed. Set at init
nameUTF-8 string (≤32 bytes)Human-readable market name. Editable via update-lending-market-name or full config update
quote_currencyUTF-8 string (≤32 bytes)Reference unit prices are denominated in. Almost always "USD"

Ownership

FieldTypeDescription
lending_market_ownerPubkeyActive market owner. Authorized for all updates
lending_market_owner_cachedPubkeyStaging slot for ownership transfer. The current owner sets it; only that pubkey can finalize the swap via update-lending-market-owner
emergency_councilPubkeyOptional separate authority for emergency-only handlers (e.g., socialize_loss)
proposer_authorityPubkeyAuthority that can propose certain config updates without holding full owner privileges
immutableu8 (bool)If 1, all owner-side updates are permanently disabled. Irreversible.

Feature flags

FieldTypeDescription
borrow_disabledu8 (bool)If 1, new borrows are rejected market-wide. Existing positions continue
emergency_modeu8 (bool)If 1, market-wide emergency mode
autodeleverage_enabledu8 (bool)If 1, enables auto-deleverage market-wide. Per-reserve flag must also be set
price_triggered_liquidation_disabledu8 (bool)If 1, blocks all price-triggered liquidations
mature_reserve_debt_liquidation_enabledu8 (bool)If 1, allows liquidations of mature fixed-term debt
obligation_borrow_debt_term_liquidation_enabledu8 (bool)If 1, enables term-based liquidation flow specifically

Withdrawal queue

FieldTypeDescription
withdraw_ticket_issuance_enabledu8 (bool)If 1, users can call enqueue-to-withdraw
withdraw_ticket_redemption_enabledu8 (bool)If 1, users can call withdraw-queued-liquidity
withdraw_ticket_cancellation_enabledu8 (bool)If 1, users can call cancel-withdraw-ticket
min_withdraw_queued_liquidity_valueu64Minimum USD value (scaled fraction) for a single ticket. Below this, enqueue-to-withdraw reverts
See Withdrawal queue.

Borrow orders

FieldTypeDescription
borrow_order_creation_enabledu8 (bool)If 1, users can call set-borrow-order
borrow_order_execution_enabledu8 (bool)If 1, lenders can call fill-borrow-order
min_borrow_order_fill_valueu64Minimum USD value (scaled fraction) for a single fill
See Borrow orders.

Obligation orders

FieldTypeDescription
obligation_order_creation_enabledu8 (bool)If 1, users can call set-obligation-order
obligation_order_execution_enabledu8 (bool)If 1, executors can call fill-obligation-order
See Obligation orders.

Fixed-term rollover

FieldTypeDescription
fixed_term_rollover_window_duration_secondsu64Window before maturity allowing fixed→fixed rollover. 0 disables
open_term_rollover_window_duration_secondsu64Window before maturity allowing fixed→open rollover. 0 disables
obligation_borrow_migration_to_fixed_execution_enabledu8 (bool)If 1, allows open→fixed migration anytime
obligation_borrow_rollover_configuration_enabledu8 (bool)If 1, allows borrowers to pre-configure rollover behavior
min_partial_rollover_valueu64Minimum USD value for a partial rollover. 0 requires full rollovers only
term_based_full_liquidation_duration_secsu64Time after maturity before full (close-factor-bypassing) liquidation is available. 0 disables
See Fixed rate reserves.

Liquidation tunables

FieldTypeDescription
liquidation_max_debt_close_factor_pctu8 (0–100)Maximum portion of debt liquidatable per round
max_liquidatable_debt_market_value_at_onceu64Hard ceiling on market value liquidated per liquidation
min_full_liquidation_value_thresholdu64Below this debt market value, the close-factor cap is bypassed
insolvency_risk_unhealthy_ltv_pctu8 (0–100)LTV threshold for the insolvency-risk auto-deleverage path
min_value_skip_liquidation_ltv_checksu64Below this market value, skip LTV health checks during liquidation
min_value_skip_liquidation_bf_checksu64Below this market value, skip borrow-factor health checks
individual_autodeleverage_margin_call_period_secsu64Default grace period (seconds) between margin call and forced liquidation
See Liquidations and Auto-deleverage.

Elevation groups

"elevation_groups": [
  {
    "id": 1,
    "ltv_pct": 90,
    "liquidation_threshold_pct": 92,
    "max_liquidation_bonus_bps": 200,
    "allow_new_loans": 1,
    "max_reserves_as_collateral": 8,
    "debt_reserve": "<DEBT_RESERVE_PUBKEY>"
  }
  // ... up to 32 entries
]
FieldTypeDescription
idu8 (1–32)Group identifier. 0 is the “no group” sentinel
ltv_pctu8 (0–100)Group LTV; replaces per-reserve LTV for in-group positions
liquidation_threshold_pctu8 (0–100)Group liquidation threshold
max_liquidation_bonus_bpsu16Cap on liquidator bonus inside the group
allow_new_loansu8 (bool)0 blocks new borrows in the group; existing positions persist
max_reserves_as_collateralu8Maximum distinct collateral reserves a group-position may hold
debt_reservePubkeySingle permitted debt asset for the group
See Elevation groups.

Position thresholds

FieldTypeDescription
min_initial_deposit_amountu64Minimum amount required for a brand-new deposit to a reserve
min_net_value_in_obligation_sfu128 (scaled fraction)Minimum USD value an obligation must hold after any operation
global_allowed_borrow_valueu64Maximum total borrow value across all users on the market

Fees

FieldTypeDescription
referral_fee_bpsu16Referral fee in basis points, shared with registered referrers

Oracle policy

FieldTypeDescription
price_refresh_trigger_to_max_age_pctu8 (0–100)Percentage of maxAgePriceSeconds at which off-chain bots refresh proactively. 0 = on-demand only

Runtime / read-only

These fields are program-managed and not user-editable:
FieldTypeDescription
versionu64Program version
bump_seedu64PDA bump
reserved0, reserved1, padding1, padding2, elevation_group_paddingvariesStruct alignment / future-use slots

Reading the live config

yarn kamino-manager download-lending-market-config \
  --lending-market <MARKET_ADDRESS>
For market + every reserve in one call:
yarn kamino-manager download-lending-market-config-and-all-reserves-configs \
  --lending-market <MARKET_ADDRESS>

Reference