LLM Notice: This documentation site supports content negotiation for AI agents. Request any page with Accept: text/markdown or Accept: text/plain header to receive Markdown instead of HTML. Alternatively, append ?format=md to any URL. All markdown files are available at /md/ prefix paths. For all content in one file, visit /llms-full.txt
Skip to main content

Understanding FCM Basics

To understand how Flow Credit Market (FCM) works, let's build up from simple lending concepts to FCM's innovative three-component architecture.

From Traditional Lending to FCM

Level 1: Traditional Lending (Aave, Compound)

In traditional DeFi lending protocols:


_10
graph LR
_10
User[User] -->|Deposit FLOW| Protocol[Lending Protocol]
_10
Protocol -->|Borrow USDC| User
_10
User -->|Repay + Interest| Protocol
_10
_10
style Protocol fill:#bbf,stroke:#333,stroke-width:2px

How it works:

  1. Deposit collateral (e.g., 1000 FLOW worth $1000)
  2. Borrow up to ~75% of collateral value (e.g., $750 USDC)
  3. Pay interest on borrowed amount
  4. Your responsibility: Monitor health factor and manually manage position

Limitations: Traditional lending requires you to manually monitor and rebalance positions, quickly add collateral or repay debt if collateral price drops, manually deploy borrowed funds to avoid them sitting idle, and act fast enough to prevent liquidation.

Level 2: Automated Lending (ALP)

ALP adds automation to traditional lending:


_10
graph LR
_10
User[User] -->|Deposit FLOW| ALP[ALP Position]
_10
ALP -->|Auto-borrow MOET| User
_10
_10
Price[Price Drop] -.->|Triggers| Rebalance[Auto-Rebalance]
_10
Rebalance -->|Pulls funds| Source[TopUpSource]
_10
Source -->|Repays debt| ALP
_10
_10
style ALP fill:#f9f,stroke:#333,stroke-width:2px

New features:

  • Auto-borrowing: Automatically borrows optimal amount when you deposit
  • Auto-rebalancing: Maintains target health ratio automatically
  • TopUpSource integration: Can pull from external sources to prevent liquidation

Better, but:

  • ⚠️ TopUpSource must have funds available
  • ⚠️ Borrowed MOET still needs manual deployment for yield
  • ⚠️ Still some manual intervention required

Level 3: FCM (ALP + FYV + MOET)

FCM completes the automation by adding yield generation:


_15
graph TB
_15
User[User] -->|1. Deposit FLOW| ALP[ALP Position]
_15
ALP -->|2. Auto-borrow MOET| DrawDown[DrawDownSink]
_15
DrawDown -->|3. Deploy| FYV[FYV Strategy]
_15
FYV -->|4. Generate yield| Yield[Yield Tokens]
_15
_15
Price[Price Drop] -.->|Triggers| ALP
_15
FYV -->|5. Provide liquidity| TopUp[TopUpSource]
_15
TopUp -->|6. Repay debt| ALP
_15
_15
Yield -.->|Accumulates| FYV
_15
_15
style ALP fill:#f9f,stroke:#333,stroke-width:4px
_15
style FYV fill:#bfb,stroke:#333,stroke-width:4px
_15
style MOET fill:#fbb,stroke:#333,stroke-width:2px

Complete automation:

  • Auto-borrowing: Instantly borrow optimal amount
  • Auto-deployment: Borrowed MOET flows directly to yield strategies
  • Auto-compounding: FYV strategies reinvest yields
  • Auto-protection: FYV provides liquidity to prevent liquidations
  • Auto-everything: True set-and-forget experience

The breakthrough:

  • 🎯 Yield protects your position: Your generated yield maintains health automatically
  • 🎯 No manual intervention: Everything happens automatically
  • 🎯 Capital efficiency: Borrowed capital works for you immediately

Understanding the Three Components

Component 1: ALP (The Lending Engine)

What it does: Manages collateral and debt positions with automated rebalancing.

Key concepts:

  • Collateral: Assets you deposit (FLOW, stFLOW, etc.)
  • Collateral Factor: Percentage of collateral value you can borrow (e.g., 0.8 = 80%)
  • Health Factor: Ratio of collateral to debt (must be > 1.0)
  • Target Health: Optimal ratio the system maintains (typically 1.3)

Example:


_10
Deposit: 1000 FLOW @ $1 = $1000
_10
Collateral Factor: 0.8 (80%)
_10
Effective Collateral: $800
_10
_10
Target Health: 1.3
_10
Max Safe Borrow: $800 / 1.3 ≈ $615.38 MOET
_10
_10
ALP auto-borrows: 615.38 MOET
_10
Position Health: 800 / 615.38 = 1.3 ✓

Learn more: ALP Documentation

Component 2: FYV (The Yield Engine)

What it does: Deploys capital into yield-generating strategies and provides liquidity for liquidation prevention.

Key concepts:

  • Strategies: Predefined yield-generating approaches (TracerStrategy, etc.)
  • AutoBalancer: Manages exposure to yield tokens and rebalancing
  • DrawDownSink: Receives borrowed MOET from ALP
  • TopUpSource: Provides liquidity back to ALP when needed

Example strategy (TracerStrategy):


_10
1. Receive MOET from ALP → DrawDownSink
_10
2. Swap MOET → YieldToken (e.g., LP token, farm token)
_10
3. Hold YieldToken in AutoBalancer
_10
4. Accumulate yield over time
_10
5. When ALP needs funds:
_10
- Swap YieldToken → MOET
_10
- Provide via TopUpSource
_10
- ALP repays debt

Learn more: FYV Documentation

Component 3: MOET (The Unit of Account)

What it does: Serves as the currency for all operations - borrowed asset, pricing unit, and value transfer medium.

Key concepts:

  • Unit of Account: All prices quoted in MOET (FLOW/MOET, USDC/MOET)
  • Primary Borrowed Asset: What ALP auto-borrows and what FYV receives
  • Synthetic Stablecoin: Value pegged to maintain stability
  • Medium of Exchange: Flows between ALP and FYV

Why MOET?: MOET standardizes all valuations, simplifies multi-collateral calculations, is designed specifically for DeFi operations, and provides deep integration with the Flow ecosystem.

Learn more: MOET Documentation

The Capital Flow Cycle

Let's follow $1000 of FLOW through the entire FCM system:

Phase 1: Initial Deposit and Borrowing


_17
You deposit: 1000 FLOW worth $1000
_17
_17
ALP calculates:
_17
- Effective collateral: $1000 × 0.8 = $800
_17
- Target health: 1.3
_17
- Borrow amount: $800 / 1.3 = $615.38 MOET
_17
_17
ALP auto-borrows: 615.38 MOET
_17
_17
MOET flows to: FYV strategy (via DrawDownSink)
_17
_17
FYV swaps: 615.38 MOET → 615.38 YieldToken
_17
_17
Status:
_17
- Your ALP position: 1000 FLOW collateral, 615.38 MOET debt
_17
- Your FYV position: 615.38 YieldToken generating yield
_17
- Health factor: 1.3 ✓

Phase 2: Yield Generation


_14
Time passes...
_14
_14
FYV Strategy generates yield:
_14
- Trading fees from LP positions
_14
- Farming rewards
_14
- Interest from lending
_14
_14
Example after 1 month:
_14
- YieldToken value: 615.38 → 625.00 (+1.5% return)
_14
- Yield earned: ~$10
_14
_14
FYV holds:
_14
- Original: 615.38 YieldToken
_14
- Plus accumulated yield

Phase 3: Price Drop & Auto-Protection


_24
FLOW price drops: $1.00 → $0.80 (-20%)
_24
_24
ALP detects:
_24
- Collateral: 1000 FLOW @ $0.80 = $800 × 0.8 = $640 effective
_24
- Debt: 615.38 MOET
_24
- New health: 640 / 615.38 = 1.04 (below min 1.1!)
_24
_24
ALP triggers rebalancing:
_24
- Calculates required repayment
_24
- Target debt: $640 / 1.3 = $492.31 MOET
_24
- Needs to repay: 615.38 - 492.31 = 123.07 MOET
_24
_24
ALP pulls from FYV (TopUpSource):
_24
- FYV swaps: 123.07 YieldToken → 123.07 MOET
_24
- Sends MOET to ALP
_24
_24
ALP repays debt:
_24
- New debt: 492.31 MOET
_24
- New health: 640 / 492.31 = 1.3 ✓
_24
_24
Status:
_24
- ALP position: 1000 FLOW, 492.31 MOET debt, HF=1.3
_24
- FYV position: ~492 YieldToken remaining
_24
- Liquidation prevented! ✓

Phase 4: Price Recovery


_24
FLOW price recovers: $0.80 → $1.00
_24
_24
ALP detects:
_24
- Collateral: 1000 FLOW @ $1.00 = $1000 × 0.8 = $800 effective
_24
- Debt: 492.31 MOET
_24
- New health: 800 / 492.31 = 1.625 (above max 1.5!)
_24
_24
ALP triggers rebalancing:
_24
- Can borrow more to reach target health
_24
- Target debt: $800 / 1.3 = $615.38 MOET
_24
- Can borrow: 615.38 - 492.31 = 123.07 MOET
_24
_24
ALP auto-borrows:
_24
- Borrows: 123.07 MOET
_24
- Pushes to FYV (DrawDownSink)
_24
_24
FYV deploys:
_24
- Swaps: 123.07 MOET → 123.07 YieldToken
_24
- Back to ~615 YieldToken
_24
_24
Status:
_24
- ALP position: 1000 FLOW, 615.38 MOET debt, HF=1.3
_24
- FYV position: ~615 YieldToken generating yield
_24
- Fully rebalanced and optimized! ✓

Key Benefits Explained

1. Yield-Powered Liquidation Prevention

Traditional protocol:


_10
Price drops → Health factor drops → You must manually:
_10
1. Monitor the drop
_10
2. Decide: add collateral or repay debt?
_10
3. Find liquidity
_10
4. Execute transaction
_10
5. Hope you're not liquidated first

FCM:


_10
Price drops → Health factor drops → System automatically:
_10
1. Detects drop instantly
_10
2. Calculates exact repayment needed
_10
3. Pulls from your yield
_10
4. Repays debt
_10
5. Restores health
_10
_10
All in one transaction, no intervention needed!

2. Capital Efficiency

Without FCM:


_16
Scenario: Have 1000 FLOW, want to generate yield
_16
_16
Option A: Just hold FLOW
_16
- Capital: $1000 working
_16
- Opportunity cost: Missing yield opportunities
_16
_16
Option B: Deposit in lending protocol
_16
- Earn deposit interest: ~3% APY
_16
- Capital: $1000 working
_16
- Yield: ~$30/year
_16
_16
Option C: Manual yield farming
_16
- Borrow against FLOW: ~$750
_16
- Deploy to farm: Complex, risky
_16
- Must monitor constantly
_16
- Risk liquidation

With FCM:


_10
Deposit 1000 FLOW → FCM does everything:
_10
- Borrow optimal amount: ~$615 MOET
_10
- Deploy to best yield: Automatic
_10
- Compound returns: Automatic
_10
- Prevent liquidation: Automatic
_10
- Potential yield: 5-15% APY (varies by strategy)
_10
_10
Capital efficiency: Using collateral to earn yield on borrowed funds
_10
Risk management: Yield protects against liquidation
_10
Effort: Set and forget

3. Composability

Each component has value independently:

Use ALP alone when you:

  • Want simple lending/borrowing
  • Have your own yield strategies
  • Need DeFi Actions integration

Use FYV alone when you:

  • Want yield aggregation
  • Don't need leverage
  • Prefer direct yield farming

Use FCM together when you:

  • Want maximum automation
  • Desire liquidation protection
  • Seek optimal capital efficiency

Understanding the Math

Health Factor Calculation


_10
Health Factor = Effective Collateral / Effective Debt
_10
_10
Effective Collateral = Token Amount × Price × Collateral Factor
_10
Effective Debt = Borrowed Amount × Price
_10
_10
Example:
_10
- 1000 FLOW @ $1 each × 0.8 factor = $800 effective collateral
_10
- 615.38 MOET @ $1 each = $615.38 effective debt
_10
- Health Factor = 800 / 615.38 = 1.30

Target Health Ranges


_10
Health Factor States:
_10
_10
HF < 1.0 → Liquidatable (immediate danger!)
_10
HF = 1.0-1.1 → At risk (very close to liquidation)
_10
HF = 1.1-1.3 → Below target (should rebalance up)
_10
HF = 1.3 → Target (optimal!)
_10
HF = 1.3-1.5 → Above target (can borrow more)
_10
HF > 1.5 → Overcollateralized (should rebalance down)

Borrowing Capacity


_10
Maximum Safe Borrow = Effective Collateral / Target Health
_10
_10
Example with target health of 1.3:
_10
- Effective collateral: $800
_10
- Max borrow: $800 / 1.3 = $615.38 MOET
_10
_10
Why not borrow more?
_10
- Need safety buffer for price volatility
_10
- Target of 1.3 means 30% buffer above liquidation
_10
- If you borrowed $800, health would be 1.0 (liquidatable immediately!)

Learn more: Mathematical Foundations

Common Questions

How does FCM differ from Uniswap V3?

Uniswap V3 evolved from V2 by adding:

  • Concentrated liquidity (specific price ranges)
  • Multiple fee tiers
  • Capital efficiency improvements
  • More complex LP management

FCM evolves from basic lending by adding:

  • Automated position management
  • Yield generation integration
  • Liquidation prevention via yield
  • Multi-component architecture (ALP + FYV + MOET)

Both are "evolved" versions of simpler protocols, adding complexity for better capital efficiency.

Can I use FCM without understanding all three components?

Yes! Think of it like using a car:

  • User level: Just drive (deposit and earn yield)
  • Enthusiast level: Understand the engine (how ALP, FYV, and MOET connect)
  • Builder level: Modify and extend (create custom strategies)

Start with user level, learn more as you go.

What happens if FYV doesn't have enough liquidity for rebalancing?

Multiple fallback mechanisms:

  1. Primary: FYV provides from yield
  2. Secondary: FYV can exit positions partially
  3. Tertiary: Traditional liquidation (external liquidators)
  4. Emergency: Circuit breakers and admin intervention

The system is designed with multiple safety layers.

Is my yield always enough to prevent liquidation?

Not guaranteed, but highly likely because you're earning yield continuously, the system only pulls what's needed, the health buffer (1.3 target) provides cushion, and you can deposit more collateral anytime. Traditional protocols have 0% chance of automatic prevention - FCM gives you a strong automatic defense.

Next Steps

Now that you understand the basics:

  1. Learn the architecture: Architecture Overview
  2. Understand the math: Mathematical Foundations
  3. Explore components: ALP, FYV, MOET
  4. Start using FCM: Follow the quick start guide

Key Takeaway

FCM = Traditional Lending + Automation + Yield Generation + Liquidation Protection

It's not just "another lending protocol" - it's a complete yield-generating system with automated risk management.