Skip to content

Manage Markets & Liquidity (Vaults V1)

As a curator for a Morpho Vault V1, your primary responsibilities are to manage which markets the vault can supply to, set risk limits via supply caps, and organize the flow of capital using supply and withdraw queues.

This guide provides a comprehensive overview of how to perform these actions using two methods:

  1. The Curator App: A user-friendly interface for most management tasks.
  2. Direct Contract Calls: For advanced users or scripted interactions via Etherscan.

Managing Supply Caps

Supply caps are the primary tool for controlling a vault's risk exposure to any single Morpho Market.

Using the Curator App

Navigate to the Caps tab in the Curator App to view and manage all active and pending market caps.

Morpho Vault V1 supply caps interface

Modifying or Adding a New Cap

Click "+ New" Button

Click the "+ New" button in the top right to open the market selection modal.

Select a market to set a cap
Select a Market and Set the Cap

Choose the market you want to enable or modify. Set the desired Supply Cap value and click Submit New Cap. Setting a non-zero cap for the first time will enable the market in your vault.

Submitting a new supply cap
Wait for the Timelock and Accept

Increasing a cap is a timelocked action. After submitting, the proposal will appear in the Pending tab. Once the timelock expires (shown under "Estimated Valid At"), you must click Accept to finalize the change. Decreasing a cap is instant.

Accepting a pending cap change

Using Direct Contract Calls

1. Submit the Cap (submitCap)

Execute submitCap with the market's parameters and the desired cap amount. The newSupplyCap should be in the native decimals of the loan token.

Etherscan interface for submitCap
Submitting a cap via Etherscan.

2. Accept the Cap (acceptCap)

After the timelock period expires, anyone can call acceptCap with the same market parameters to finalize the change.

Etherscan interface for acceptCap
Accepting a cap via Etherscan.

Managing Queues

The Supply and Withdraw Queues dictate the logic for capital allocation. The Allocator role is responsible for their management.

Using the Curator App

Navigate to the Queues section to view and manage your vault's queues.

Morpho Vault V1 queues interface

Reordering a Queue

  1. Click the Edit button for the queue you wish to modify.
  2. Drag and drop the market cards into your desired order.
  3. Click Save and confirm the transaction.
Reordering a queue by dragging and dropping markets

Using Direct Contract Calls

Setting the Supply Queue (setSupplyQueue)

To set the supply queue, call setSupplyQueue with an array of market Ids in the desired order.

# Example input for setSupplyQueue
[0xc54d7acf14de29e0e5527cabd7a576506870346a78a11a6762e2cca66322ec41, 0x_MARKET_ID_2, ...]

Updating the Withdraw Queue (updateWithdrawQueue)

To reorder the withdraw queue, call updateWithdrawQueue with an array of numbers representing the original indexes of the markets in their new desired order.

For example, if the original queue was [MarketA, MarketB, MarketC] (indexes [0, 1, 2]) and you want the new order to be [MarketC, MarketA, MarketB], you would call updateWithdrawQueue([2, 0, 1]).

Delisting a Market

Delisting a market is a multi-step process to ensure funds are safely migrated.

Standard Delisting Process

This process safely removes a market without losing funds.

1. Set Market Cap to Zero

Instantly set the market's supply cap to 0 using submitCap. This prevents new allocations to the market.

2. Reallocate All Liquidity

Use reallocate to move all of the vault's assets out of the target market and into other active markets. Ensure the market to be delisted is not included in the reallocate call.

3. Update the Withdraw Queue

Once the market's cap and the vault's allocation are both zero, call updateWithdrawQueue with a new index array that omits the delisted market.

Emergency Market Removal

This process should only be used if a market is malfunctioning and funds cannot be safely reallocated.

1. Submit Market for Removal

As the Curator, call submitMarketRemoval with the parameters of the market to be force-removed.

2. Wait for the Timelock

A timelock period begins, allowing users to react.

3. Update the Withdraw Queue

After the timelock expires, the Allocator can call updateWithdrawQueue to remove the market, even if it still contains vault assets.

Delisting Process Summary

For safe market delisting:

  1. Remove the market from the supply queue
  2. Reduce the market cap to zero
  3. Reallocate all funds from the market to other markets
  4. Remove the market from the withdraw queue

For emergency situations:

  1. Submit market removal
  2. Wait for timelock to elapse
  3. Update the withdraw queue

Always prioritize the safety of depositor funds and provide clear communication throughout the delisting process.