Add Covenant (Monad) Yield Coin pools#2681
Conversation
|
Warning Rate limit exceeded
You’ve run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThis PR adds a complete Covenant protocol adaptor to DefiLlama's yield-server for the Monad chain. It includes contract ABI definitions, market discovery and data fetching utilities, APY and TVL computation logic, and a formatted pool export function. ChangesCovenant Adaptor for Monad Chain
Sequence DiagramsequenceDiagram
participant Adaptor as apy() orchestrator
participant Chain as Monad Chain
participant Covenant as Covenant Contract
participant DataProvider as Data Provider
participant LlamaAPI as DefiLlama API
Adaptor->>Covenant: listMarketIds() fetch CreateMarket events
Covenant-->>Adaptor: marketIds[]
Adaptor->>DataProvider: getMarketsDetails(marketIds)
DataProvider->>Chain: query market state & params
Chain-->>DataProvider: MarketDetails[]
DataProvider-->>Adaptor: market data
Adaptor->>LlamaAPI: fetchMonUsdPrice()
LlamaAPI-->>Adaptor: monUsdPrice
Adaptor->>Adaptor: filter active markets
Adaptor->>Adaptor: computeYieldCoinApy(marketData)
Adaptor->>Adaptor: zTokenSupplyValueInQuote(marketData)
Adaptor->>Adaptor: compute tvlUsd
Adaptor-->>Adaptor: return pool[] with metrics
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
The covenant adapter exports pools: Test Suites: 1 passed, 1 total |
Matches Synthetix-v3's convention for sUSD (underlying = USDC, not SNX) and shmonad's use of WMON for MON-denominated yield. The Yield Coin (zToken) is a synthetic claim denominated in the quote unit, not in the deposited baseToken — exposing baseToken in underlyingTokens would mislead users searching the yields page.
|
The covenant adapter exports pools: Test Suites: 1 passed, 1 total |
|
The covenant adapter exports pools: Test Suites: 1 passed, 1 total |
|
The covenant adapter exports pools: Test Suites: 1 passed, 1 total |
Adds yield-server pools for Covenant on Monad. One pool per market for
the Yield Coin (zToken):
(EVMBlockchainAdapter.ts debtTokenAPYCalc), pulled from a single
DataProvider.getMarketsDetails call on Monad mainnet
converted to USD via the quote anchor (USDC = $1, MON via CoinGecko)
TVL adapter (already merged in DefiLlama-Adapters#19272):
https://defillama.com/protocol/covenant
Methodology rationale + source-of-truth ABIs:
https://github.com/covenant-labs/covenant-defillama
Summary by CodeRabbit
Release Notes