# Capital Flow

USDREFI has three primary flows: deposits in, yield cycling, and exits out.

## Deposit Flow

| Step | Action                                                | Actor           |
| ---- | ----------------------------------------------------- | --------------- |
| 1    | User approves USDC spend to vault                     | User wallet     |
| 2    | User calls `vault.deposit(amount, receiver)`          | User wallet     |
| 3    | Vault checks `tierRegistry.tierOf(receiver)` and caps | Vault contract  |
| 4    | Vault mints USDREFI to receiver at 1:1                | Vault contract  |
| 5    | Foundation Safe transfers USDC to Textile/Quipu pool  | Foundation Safe |

Step 5 is a manual operation performed by the Foundation multisig. Deposited USDC sits in the vault until the Safe operators deploy it into the curated credit pool.

## Yield Cycle

| Step | Action                                                  | Cadence      |
| ---- | ------------------------------------------------------- | ------------ |
| 1    | Quipu/Textile reports yield accrual                     | Monthly      |
| 2    | Foundation Safe receives yield                          | Monthly      |
| 3    | Foundation Safe transfers reward portion to Reward Safe | Monthly      |
| 4    | Reward Safe funds Merkl campaign (USDREFI + $REFI)      | Monthly      |
| 5    | Merkl snapshots holders and builds Merkle tree          | Configurable |
| 6    | Users claim rewards via on-chain proofs                 | On-demand    |

## Exit Flow (Swap-Only)

Users swap USDREFI for USDC on the Uniswap V4 concentrated liquidity pool, which targets a \~1:1 price in a tight range (0.995–1.005).

The Uniswap pool is the **only exit path** under normal operations:

* Protocol-owned liquidity (\~$5k) seeds the initial position
* LP incentives via a separate Merkl campaign maintain ongoing depth
* Dune dashboard monitors pool health in real-time
* If liquidity drops below threshold, the Foundation Safe can toggle emergency vault withdrawals

## Foundation Safe

Gnosis Safe with 2-of-3 threshold. Signers: Monty, Luuk, and one additional trusted party. Responsibilities:

* Hold deposited USDC and deploy to Textile/Quipu
* Receive yield returns and transfer reward portion to Reward Safe
* Set/adjust vault parameters (global cap, per-tier caps)
* Override TierRegistry entries and change API signer address
* Toggle emergency withdrawals

## Reward Safe

Separate Gnosis Safe (same signers) holding USDREFI + $REFI for distribution. Funded periodically by the Foundation Safe from yield proceeds. Deposits tokens into Merkl campaigns.
