Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
5547 commits
Select commit Hold shift + click to select a range
9388669
Merge pull request #2185 from KPHEMRAJ/40-acres-bh
slasher125 Nov 4, 2025
993e489
Merge pull request #2186 from metrom-xyz/master
slasher125 Nov 4, 2025
46f3649
feat: intro frankencoin lending integration
samclassix Nov 4, 2025
3c5b087
feat: removed unused props, token address to lower case
samclassix Nov 4, 2025
f4791d5
feat: integrated borrowPools via borrow position v2
samclassix Nov 4, 2025
56a5546
feat: remove debuging console.log
samclassix Nov 4, 2025
2af4ac2
feat: url to actual borrow position
samclassix Nov 4, 2025
cac0880
update rpc env
slasher125 Nov 5, 2025
1726b29
Merge pull request #2188 from Frankencoin-ZCHF/add-frankencoin-yield-…
slasher125 Nov 5, 2025
798c90d
feat: add rocky sUSDr
FabienCoutant Nov 5, 2025
fd04606
Merge branch 'DefiLlama:master' into feat/add-rocky
FabienCoutant Nov 5, 2025
c0373f2
add bsc pools
nvduc91 Nov 7, 2025
edbcd72
Merge pull request #2191 from nvduc91/feat/kyber-add-arbitrum
slasher125 Nov 7, 2025
4f20592
fix starknet rpc
slasher125 Nov 11, 2025
f481c37
bex fix
slasher125 Nov 11, 2025
8789d1b
fix velodrome v3 sugar
noateden Nov 11, 2025
8b50aa6
added saga vyusd
neelra8n Nov 11, 2025
fd69967
Fix nest-credit adaptor: add APY logic and required fields
kristinatub Nov 11, 2025
5b8da40
Merge branch 'DefiLlama:master' into fix/nest-credit-apy-simple
kristinatub Nov 11, 2025
5bd68b1
feat: Add Isle Finance adapter
Jung0x12 Nov 12, 2025
abc6d20
Merge pull request #2195 from neelra8n/master
slasher125 Nov 12, 2025
f4ae12b
Merge pull request #2197 from isle-labs/isle-finance
slasher125 Nov 12, 2025
e3626a1
exclude
slasher125 Nov 12, 2025
7a6bd3c
Add yieldBearingTokens (#1)
AnshcSigma Nov 12, 2025
0b87f3a
fix velo v3
slasher125 Nov 12, 2025
0afaaa2
chore: update reserve protocol apys
JuampiRombola Nov 12, 2025
86a25d7
morpho-v1, show OP rewards
slasher125 Nov 13, 2025
cd95993
Merge pull request #2198 from AnshcSigma/master
slasher125 Nov 13, 2025
c4ad084
Merge pull request #2199 from JuampiRombola/master
slasher125 Nov 13, 2025
ee50d64
Merge pull request #2189 from rocky-protocol/feat/add-rocky
slasher125 Nov 13, 2025
fc36cc5
chore(silo-v2): exclude stream-impacted markets and vaults
JayWelsh Nov 14, 2025
6b9205d
adding kaspacom-dex yields
giladm11 Nov 13, 2025
01d1963
fix polynomial-liquidit
slasher125 Nov 18, 2025
6f24ceb
Merge pull request #2200 from giladm11/adding-kaspacom-dex-yields
slasher125 Nov 18, 2025
af15ec9
notional-v3 fix
slasher125 Nov 18, 2025
44c31ab
fix stakedao
slasher125 Nov 18, 2025
e28476a
feat: wstlink
palace22 Nov 18, 2025
0a7f62c
add btcfi project
tlatkdgus1 Nov 20, 2025
bbaaa48
Merge pull request #2201 from silo-finance/feat/silo-v2-vault-support
slasher125 Nov 20, 2025
5e287d0
Merge pull request #2202 from palace22/feat/wstlink
slasher125 Nov 20, 2025
412d89e
rename btcfi to btcfi-cdp, update adaptors logic
tlatkdgus1 Nov 21, 2025
f7d1c46
Fix orca-dex
calintje Nov 21, 2025
d5908af
try fix velodrome v3 missing pools
noateden Nov 21, 2025
429c3a7
remove addresses from exclusion
slasher125 Nov 22, 2025
cef4bb8
fix
slasher125 Nov 22, 2025
c959880
add yuzu-money
lucasgleba Nov 24, 2025
68bd91d
adding yield for iaero
iaeroProtocol Nov 24, 2025
7b1a178
feat: monad chain and tokens
palace22 Nov 24, 2025
77d3ffd
Merge branch 'DefiLlama:master' into fix/nest-credit-apy-simple
kristinatub Nov 24, 2025
3335ccd
update sdk
slasher125 Nov 25, 2025
87ce5c3
Merge pull request #2208 from palace22/folks-finance/monad-tokens
slasher125 Nov 25, 2025
7609cff
Merge pull request #2196 from kristinatub/fix/nest-credit-apy-simple
slasher125 Nov 25, 2025
034fd5c
nest-credit fix urls
slasher125 Nov 25, 2025
d6f19cc
Merge pull request #2206 from Telos-Consilium/yuzu-money
slasher125 Nov 25, 2025
c582ed8
add rpc
slasher125 Nov 25, 2025
5836458
update axios
tlatkdgus1 Nov 25, 2025
b782b22
rename project to iaero-protocol as requested
iaeroProtocol Nov 25, 2025
11238f2
revert package-lock.json
iaeroProtocol Nov 25, 2025
e1da180
feat: add Monad chain support to Gearbox protocol adapter
alex0xhodler Nov 25, 2025
8f14f7d
Merge pull request #2207 from alex0xhodler/feature/gearbox-on-monad
slasher125 Nov 25, 2025
45821bd
Merge pull request #2203 from tlatkdgus1/master
slasher125 Nov 25, 2025
8e33a7b
Merge pull request #2209 from iaeroProtocol/master
slasher125 Nov 25, 2025
d445791
add hyperliquid graph URL to the graphUrls configuration
Dakavon Nov 25, 2025
0e7c720
Add nabla indexer pool metrics fetching for Monad
Dakavon Nov 25, 2025
6dccbc1
Merge pull request #2204 from calintje/fix/orca-dex
slasher125 Nov 26, 2025
2c4e485
Merge pull request #2210 from NablaFinance/update-nablaFinance-hyperE…
slasher125 Nov 26, 2025
9a86ebf
feat: add native-credit-pool yields
June-native Nov 27, 2025
fe4e706
Update Size Credit API
aviggiano Nov 28, 2025
6f14d4d
Rename size-credit to rheo adaptor
aviggiano Nov 28, 2025
75f25a6
Create index.js
Codonyat Nov 28, 2025
e46d879
feat:gmon
palace22 Dec 1, 2025
c7edc0d
fix and update pendle
noateden Dec 1, 2025
86bf87c
add llama indexer secrets
0xngmi Dec 1, 2025
18e37ca
feat(gearbox): add AUSD pool on Monad with MON rewards (#2215)
alex0xhodler Dec 2, 2025
aa053ac
feat(Vaults-V2): adding contribution of vaults-v2 into morpho-v1 (#2217)
tomrpl Dec 2, 2025
635247e
Shmonad pr (#2218)
noateden Dec 2, 2025
af3ec0a
add ramses-hl yields
0xShad0w Dec 3, 2025
6ef642e
fix phar-v3 yields
0xShad0w Dec 3, 2025
6effa0b
fix
0xShad0w Dec 3, 2025
2cee326
fix(yo-protocol): streamline URL formatting and add support for yoGOL…
kraikov Dec 3, 2025
8056e27
update from alchemy to goldsky
frontier159 Dec 4, 2025
db7ded4
- Added 32 isolated RIZ lending pools across Arbitrum, BSC, and Base
0xKonstantin Dec 4, 2025
c5b2b6e
Merge pull request #2223 from 0xKonstantin/master
g1nt0ki Dec 4, 2025
1be0dc0
Add Monad for Morpho v1
iamvukasin Dec 4, 2025
5bfbcd4
Merge pull request #2211 from June-native/feat/native
slasher125 Dec 8, 2025
96c6d7c
Merge pull request #2212 from aviggiano/update-endpoint-rheo
slasher125 Dec 8, 2025
748cfd4
Merge pull request #2216 from palace22/folks-finance/gmon
slasher125 Dec 8, 2025
f9b03f7
Merge pull request #2221 from yoprotocol/master
slasher125 Dec 8, 2025
19b5c9c
Merge pull request #2222 from frontier159/origami-goldsky
slasher125 Dec 8, 2025
82d5f7e
Merge pull request #2224 from iamvukasin/monad-morpho-v1
slasher125 Dec 8, 2025
325a1f7
Merge pull request #2220 from 0xShad0w/phar-v3
slasher125 Dec 8, 2025
3564463
uniswap-v2 fix url
slasher125 Dec 8, 2025
78cd676
uni v3 fix url
slasher125 Dec 8, 2025
1bdcaf1
fix: fixed symbol and added poolmeta
Codonyat Dec 8, 2025
a5483cd
Merge pull request #2213 from Codonyat/master
slasher125 Dec 8, 2025
fe8f181
Add Monad for PancakeSwap AMM
iamvukasin Dec 8, 2025
3c1be85
feat: add Flare, Monad on Spectra
Ulydev Dec 8, 2025
3c94518
feat adding yeild to magma protocol
diyahir Dec 8, 2025
46b6174
Update index.js
diyahir Dec 8, 2025
c61d62c
Update index.js
diyahir Dec 8, 2025
832a028
moving ´magma-protocol´ to ´magma-staking´
diyahir Dec 8, 2025
23671cf
Merge pull request #2225 from iamvukasin/monad-pancakeswap-amm
slasher125 Dec 8, 2025
08709a1
Update API URL for Ekubo to Starknet mainnet
Define101 Dec 8, 2025
ada3243
Add Accountable integration for loan vaults and yield calculations
pawell24 Dec 9, 2025
da0f034
remove stream-finance
slasher125 Dec 10, 2025
10ea47a
add additional exclusion checks
slasher125 Dec 10, 2025
b1a088a
add ramses-hl-cl yields
0xShad0w Dec 10, 2025
c548209
fix protocol
0xShad0w Dec 10, 2025
1750a60
Enhance Accountable integration by adding Merkl rewards fetching and …
pawell24 Dec 10, 2025
9b1359c
update exclusion list
slasher125 Dec 11, 2025
3e7b51c
Merge pull request #2227 from diyahir/master
slasher125 Dec 11, 2025
9f4a2e4
Merge pull request #2230 from pawell24/feat/accountable
slasher125 Dec 11, 2025
7839dd8
Merge pull request #2231 from 0xShad0w/master
slasher125 Dec 11, 2025
d50bab6
fix
slasher125 Dec 11, 2025
c8ec6c2
aura update graphs
slasher125 Dec 11, 2025
0014b45
init thesauros provider
PillarDevelopment Dec 11, 2025
4151541
arb
PillarDevelopment Dec 11, 2025
1df2ad5
Update index.js
PillarDevelopment Dec 11, 2025
1e8b049
Add Kintsu for Monad
iamvukasin Dec 12, 2025
4caff4a
Merge pull request #2233 from iamvukasin/master
slasher125 Dec 15, 2025
37bec75
Merge pull request #2232 from Thesauros/master
slasher125 Dec 15, 2025
a2accae
Refactor Accountable integration to remove Merkl rewards fetching and…
pawell24 Dec 15, 2025
dbc9a81
Incorporate liquidation gains into apy calcs
RickGriff Dec 15, 2025
04bdd89
update exclusion
slasher125 Dec 15, 2025
373daa0
fix
slasher125 Dec 15, 2025
6f27dd4
update exclusion
slasher125 Dec 15, 2025
f72d1d6
add lombard-lbtc
slasher125 Dec 15, 2025
a6ad261
gmx v2 swap graph, fix
slasher125 Dec 15, 2025
3f2f4fb
Merge pull request #2234 from pawell24/feat/accountable
slasher125 Dec 16, 2025
c2c6e91
Merge pull request #2235 from RickGriff/liquity_v2_yield_adaptor
slasher125 Dec 16, 2025
32803d8
add hermes-v2 adapter and implement gauge staking APR tracking
0xBugsy Dec 17, 2025
bcb58b3
Add spark savings vaults
b-tarczynski Dec 17, 2025
7267b92
updated asset and provider names
PillarDevelopment Dec 17, 2025
fe7acf4
update exclusion
slasher125 Dec 17, 2025
aa73e35
fix: usual api apr key
slasher125 Dec 17, 2025
c4548e0
usual fix
slasher125 Dec 17, 2025
093e894
feat: shmon
palace22 Dec 17, 2025
8decce5
Refactor APY calculation logic in Accountable integration to utilize …
pawell24 Dec 17, 2025
73dceaa
Merge pull request #2237 from b-tarczynski/spark-savings
slasher125 Dec 18, 2025
22d7d42
Merge pull request #2238 from Thesauros/master
slasher125 Dec 18, 2025
e928faa
Merge pull request #2239 from palace22/folks-finance/shmon
slasher125 Dec 18, 2025
4397240
Merge pull request #2240 from pawell24/feat/accountable
slasher125 Dec 18, 2025
e4c6be9
fix: update incentive timing logic, incentive data queries and epoch …
0xBugsy Dec 18, 2025
7e670cf
feat: add APY calculation for Clober pools integration
graykode Dec 19, 2025
9b4062f
fix: simplify data structure for APY calculation
graykode Dec 19, 2025
1d7b3cc
fix: update APY calculation to handle merkleApy correctly
graykode Dec 19, 2025
1033c6c
fix avax urls
slasher125 Dec 20, 2025
b1accf7
Merge pull request #2242 from clober-dex/master
slasher125 Dec 20, 2025
f22938c
feat: add MuDigital protocol adapter
louis-mudigital Dec 22, 2025
2c860dd
Merge pull request #2243 from Mu-Digital/add/mu-digital-adapter
slasher125 Dec 22, 2025
ccec5f2
fix
slasher125 Dec 22, 2025
402425c
spark savings fix
slasher125 Dec 22, 2025
9e55dee
fix: update efficiency calculation to always use 'WIDE' preset width
0xBugsy Dec 22, 2025
0490adc
feat: add Neverland lending base & incentives APY
0xCatalyst Dec 22, 2025
92cb58c
feat: add veDUST pool with revenue rewards APY
0xCatalyst Dec 23, 2025
e8581d7
refactor: extract reward APY calculation into reusable function
0xCatalyst Dec 23, 2025
a4cf166
Merge pull request #2236 from 0xBugsy/master
slasher125 Dec 23, 2025
90fa5c2
fix: properly distinguish 0 from undefined rewards
0xCatalyst Dec 23, 2025
9a2bf37
updated provider address
PillarDevelopment Dec 24, 2025
d28431c
fix: fix veDUST pool APY calculation; replace apyReward to apyBase
0xCatalyst Dec 25, 2025
31c950c
Merge pull request #2245 from 0xCatalyst/feat/neverland-yields
slasher125 Dec 25, 2025
a483ed8
Merge pull request #2247 from Thesauros/master
slasher125 Dec 25, 2025
f23bed2
fix: revert APY from apyBase to apyReward - VEDUST
0xCatalyst Dec 26, 2025
1e12711
Project migrated to Ethereum
shakal187 Dec 27, 2025
1740990
Merge pull request #2248 from 0xCatalyst/fix/neverland-apyBase-apyReward
slasher125 Dec 27, 2025
c7a112f
Merge pull request #2249 from shakal187/master
slasher125 Dec 29, 2025
4a0792c
Merge pull request #2165 from lukajevremovic/master
slasher125 Dec 29, 2025
8689cde
fix
slasher125 Dec 29, 2025
0c3aa42
Merge pull request #2226 from Ulydev/master
slasher125 Dec 29, 2025
d7d8f51
bbSOL fix api
slasher125 Dec 29, 2025
945a2d2
kelp fix api
slasher125 Dec 29, 2025
1ca522a
uniswap v4
slasher125 Dec 29, 2025
870cef1
feat: add seamless-v2, remove seamless-v1 (#1)
chad-js Dec 29, 2025
1f60ce3
Merge pull request #2250 from chad-js/master
slasher125 Dec 30, 2025
bac0779
inverse-finance-firm fix
slasher125 Dec 30, 2025
3ac7e6d
uni v4 fix
slasher125 Dec 30, 2025
a041416
fix
slasher125 Dec 30, 2025
859201e
exclude
slasher125 Dec 30, 2025
c1450f7
exclude
slasher125 Dec 31, 2025
d996be5
Add Monad for Lagoon
iamvukasin Jan 2, 2026
e659c69
Add Kuru CLOB
iamvukasin Jan 2, 2026
50a5151
Add Monad for Merkl
iamvukasin Jan 2, 2026
0468627
Merge pull request #2251 from iamvukasin/monad-lagoon
slasher125 Jan 3, 2026
15445e2
Use quote token price to convert TVL from the API
iamvukasin Jan 5, 2026
8e898e4
Add pool meta
iamvukasin Jan 5, 2026
c05bc27
feat: add chateau yield adapter
haeli05 Jan 6, 2026
2e8dd71
Merge pull request #2253 from chateau-capital/feat/chateau-adapter
slasher125 Jan 7, 2026
240676e
Merge pull request #2252 from iamvukasin/kuru-clob
slasher125 Jan 7, 2026
9d111fe
feat: add Yusan lending protocol adapter
EnzoPlayer0ne Jan 7, 2026
01c6ad1
Add Liminal xHYPE yield adapter
Jan 7, 2026
ee27fdc
update shmon apy to 6 day window
marshabl Jan 7, 2026
765beb1
trigger build
EnzoPlayer0ne Jan 7, 2026
a295313
Merge pull request #2255 from yusanfi/master
slasher125 Jan 8, 2026
4ab7177
Merge pull request #2256 from shkkgit/feat/add-liminal-xhype-adapter
slasher125 Jan 8, 2026
a8790d4
Merge pull request #2258 from iamvukasin/monad-merkl
slasher125 Jan 8, 2026
0754ea1
move to 2 day window
marshabl Jan 8, 2026
e46e885
Fix Liminal adapter: use 7-day APY as apyBase, add multichain support
Jan 8, 2026
dd0e371
Merge pull request #2257 from FastLane-Labs/update-shmon-window
slasher125 Jan 9, 2026
13581cd
update exclusion
slasher125 Jan 9, 2026
44aacd4
merkl remove past pools
slasher125 Jan 9, 2026
fb0d4a0
update exclusion
slasher125 Jan 9, 2026
51515cf
aerodrome-v1 fix
slasher125 Jan 9, 2026
d18e549
add mstable-v2 project
paveltimosh Jan 9, 2026
d0baf32
add mstable-v2 project - fix chin mapping
paveltimosh Jan 9, 2026
6628a45
harborfi yield server
fabiaz84 Jan 10, 2026
c2fa23f
Update HarborFi adapter: calculate APR from reward streaming data
fabiaz84 Jan 11, 2026
551090f
Readme update
fabiaz84 Jan 11, 2026
740f2c1
swap to chainlink feeds
fabiaz84 Jan 11, 2026
1814de7
readme update chainlink
fabiaz84 Jan 11, 2026
727547f
poolMeta changes
fabiaz84 Jan 11, 2026
647ba18
Address CodeRabbit review: improve APR calculation and code organization
fabiaz84 Jan 11, 2026
259c4ba
Fix CodeRabbit review: BigNumber precision, token validation, checksu…
fabiaz84 Jan 11, 2026
079f1b1
feat: add APY data fetching functionality for mondayTrade
liulinhui Jan 12, 2026
7ac31b0
feat: filter pools by minimum TVL before sorting
liulinhui Jan 12, 2026
7dc1b48
feat: assign project name to pools in APY data
liulinhui Jan 12, 2026
96adcb6
Merge pull request #2259 from shkkgit/fix/liminal-use-7d-apy-as-base
slasher125 Jan 12, 2026
b00b343
change project to monday-trade-spot
liulinhui Jan 12, 2026
b2f4e71
change project to monday-trade-spot
liulinhui Jan 12, 2026
6180d51
Implement project-0 adapter to fetch bank metrics from API
SyedFaquar-MRGN Jan 12, 2026
21aef06
Remove debugging file run-harborfi.js
fabiaz84 Jan 12, 2026
a7846e8
fix slug and config
fabiaz84 Jan 12, 2026
df5ecce
fixed coderabbit comments
fabiaz84 Jan 12, 2026
8bec333
underlying asset fix
fabiaz84 Jan 12, 2026
b2e9608
fix total mcap
fabiaz84 Jan 12, 2026
fd1daf4
Merge pull request #2262 from MondayTrade/master
slasher125 Jan 13, 2026
26e05ca
add env
slasher125 Jan 13, 2026
55ca19f
Merge pull request #2263 from 0dotxyz/p0-yield-adapter
slasher125 Jan 13, 2026
3d63730
Merge pull request #2261 from fabiaz84/harborfi
slasher125 Jan 13, 2026
13dcb4f
fix
slasher125 Jan 13, 2026
252617a
fix
slasher125 Jan 13, 2026
e95933c
fix
slasher125 Jan 13, 2026
7e1685c
Add LazyUSD yield adapter
Jan 13, 2026
67a354e
Fix APY calculation to use dynamic time window
Jan 13, 2026
5156c75
Fix vault deploy block and use ethers directly
Jan 14, 2026
8c2664e
Add Neura Vaults yields adapter
maverickrrk Jan 14, 2026
7d9a307
Add defensive checks and 30-day APY data (apyMean30d)
maverickrrk Jan 14, 2026
cd15ee4
Remove apyMean30d to pass tests
maverickrrk Jan 14, 2026
74fb6a3
Use 1-day APY for apyBase and add apyBase7d as requested
maverickrrk Jan 14, 2026
b30f127
Add error handling for RPC and contract calls
Jan 14, 2026
d691a6e
Fix VAULT_DEPLOY_BLOCK to correct value (24184528)
Jan 14, 2026
4d92a95
Fix APY calculation to use strict 7-day rolling window
Jan 14, 2026
48816df
Merge pull request #2268 from maverickrrk/add-neura-vaults
slasher125 Jan 15, 2026
a570b20
Trigger CI: vault now 7+ days old, APY calculation should work
Jan 15, 2026
7b4dedf
Add both daily (apyBase) and 7-day (apyBase7d) APY calculation
Jan 15, 2026
e541f23
feat: add project x pools
kanerep Jan 15, 2026
5237941
Merge pull request #2260 from mstable/feat/add_mstable_v2
slasher125 Jan 16, 2026
e34ee4c
exclude
slasher125 Jan 16, 2026
d2f635a
Merge pull request #2269 from kanerep/feat/add-project-x
slasher125 Jan 16, 2026
1eff626
Rename adapter folder and project field to match protocol slug 'lazy'
Jan 15, 2026
17811c9
Merge pull request #2267 from sirmoremoney/add-lazyusd
slasher125 Jan 17, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
59 changes: 30 additions & 29 deletions .github/workflows/commentResult.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,36 +3,37 @@ const fetch = require('node-fetch');
const junk = 'VPTOH1X0B7rf8od7BGNsQ1z0BJk8iMNLxqrD';

async function main() {
const [, , log, author, repo, pr, path ] = process.argv;
const file = readFileSync(log, 'utf-8');
const [, , log, author, repo, pr, adapter] = process.argv;
const file = readFileSync(log, 'utf-8');

const jestError = 'FAIL src/adaptors/test.js';
const jestSuccess = 'PASS src/adaptors/test.js';
const summaryIndex = file.indexOf('Test Suites:');
const jestSuccessIndex = file.indexOf(jestSuccess);
const jestErrorIndex = file.indexOf(jestError);
let body;

const errorString = '------ ERROR ------';
const summaryIndex = file.indexOf('------ TVL ------');
const errorIndex = file.indexOf(errorString);
let body;
if (jestErrorIndex === -1 && jestSuccessIndex !== -1) {
body = `The ${adapter} adapter exports pools:
\n \n ${file.substring(summaryIndex).replaceAll('\n', '\n ')}`;
} else if (jestErrorIndex !== -1) {
body = `Error while running ${adapter} adapter:
\n \n ${file.substring(summaryIndex).replaceAll('\n', '\n ')}}`;
} else return;

if (summaryIndex != -1) {
body = `The adapter at ${path} exports TVL:
\n \n ${file.substring(summaryIndex + 17).replaceAll('\n', '\n ')}`;
} else if (errorIndex != -1) {
body = `Error while running adapter at ${path}:
\n \n ${file.split(errorString)[1].replaceAll('\n', '\n ')}`;
} else
return;

await fetch(
`https://api.github.com/repos/${author}/${repo}/issues/${pr}/comments`,
{
body,
method: "POST",
headers: {
Authorization: `token ghp_${translate(junk)}`,
Accept: 'application/vnd.github.v3+json'
}
});
};
await fetch(
`https://api.github.com/repos/${author}/${repo}/issues/${pr}/comments`,
{
body: JSON.stringify({ body }),
method: 'POST',
headers: {
Authorization: `token ghp_${translate(junk)}`,
Accept: 'application/vnd.github.v3+json',
},
}
);
}
function translate(input) {
return input ? translate(input.substring(1)) + input[0] : input;
};
main();
return input ? translate(input.substring(1)) + input[0] : input;
}
main();
24 changes: 16 additions & 8 deletions .github/workflows/getFileList.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,22 @@
const MODIFIED = parse(process.env.MODIFIED)
const ADDED = parse(process.env.ADDED)
const MODIFIED = parse(process.env.MODIFIED);
const ADDED = parse(process.env.ADDED);
const fileSet = new Set();

[...MODIFIED, ...ADDED].forEach(file => {
const [root0, root1, dir] = file.split('/')
if (root0 === 'src' && root1 === 'adaptors' && dir !=='test.js' && dir !== 'utils.js') fileSet.add(file)
})
[...MODIFIED, ...ADDED].forEach((file) => {
const [root0, root1, dir] = file.split('/');
if (
root0 === 'src' &&
root1 === 'adaptors' &&
dir !== 'test.js' &&
dir !== 'utils.js' &&
dir !== 'package.json' &&
dir !== 'package-lock.json'
)
fileSet.add(dir);
});

console.log(JSON.stringify([...fileSet]))
console.log(JSON.stringify([...fileSet]));

function parse(data) {
return data.replace('[', '').replace(']', '').split(',')
return data.replace('[', '').replace(']', '').split(',');
}
41 changes: 31 additions & 10 deletions .github/workflows/master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
deploy:
strategy:
matrix:
node-version: [14.x]
node-version: [16.x]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
Expand All @@ -17,18 +17,39 @@ jobs:
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: node scripts/createAdapterList.js
- name: Deploy infrastructure stack
run: npm run deploy
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
ETHERSCAN: ${{ secrets.ETHERSCAN}}
FANTOMSCAN: ${{ secrets.FANTOMSCAN }}
POLYGONSCAN: ${{ secrets.POLYGONSCAN }}
SNOWTRACE: ${{ secrets.SNOWTRACE }}
ARBISCAN: ${{ secrets.ARBISCAN }}
OPTIMISM: ${{ secrets.OPTIMISM }}
INFURA_CONNECTION: ${{ secrets.INFURA_CONNECTION }}
ALCHEMY_CONNECTION_POLYGON: ${{ secrets.ALCHEMY_CONNECTION_POLYGON }}
DATABASE_URL: ${{ secrets.DATABASE_URL }}
ALCHEMY_CONNECTION_ARBITRUM: ${{ secrets.ALCHEMY_CONNECTION_ARBITRUM }}
XDAI: ${{ secrets.XDAI }}
ALCHEMY_CONNECTION_ETHEREUM: ${{ secrets.ALCHEMY_CONNECTION_ETHEREUM }}
ALCHEMY_CONNECTION_POLYGON: ${{ secrets.ALCHEMY_CONNECTION_POLYGON }}
ETHEREUM_RPC: ${{ secrets.ETHEREUM_RPC }}
XDAI_RPC: ${{ secrets.XDAI_RPC }}
CRONOS_RPC: ${{ secrets.CRONOS_RPC }}
FANTOM_RPC: ${{ secrets.FANTOM_RPC }}
OPTIMISM_RPC: ${{ secrets.OPTIMISM_RPC }}
AVAX_RPC: ${{ secrets.AVAX_RPC }}
ARBITRUM_RPC: ${{ secrets.ARBITRUM_RPC }}
TRON_RPC: ${{ secrets.TRON_RPC }}
BASE_RPC: ${{ secrets.BASE_RPC }}
TVL_SPIKE_WEBHOOK: ${{ secrets.TVL_SPIKE_WEBHOOK }}
NEW_YIELDS_WEBHOOK: ${{ secrets.NEW_YIELDS_WEBHOOK }}
STALE_PROJECTS_WEBHOOK: ${{ secrets.STALE_PROJECTS_WEBHOOK }}
ZEROX_API: ${{ secrets.ZEROX_API }}
SMARDEX_SUBGRAPH_API_KEY: ${{ secrets.SMARDEX_SUBGRAPH_API_KEY }}
VENDOR_FINANCE: ${{ secrets.VENDOR_FINANCE }}
TRADERJOE: ${{ secrets.TRADERJOE }}
GRAPH_API_KEY: ${{ secrets.GRAPH_API_KEY }}
OSMOSIS_API_KEY: ${{ secrets.OSMOSIS_API_KEY}}
DUNE_API_KEY: ${{ secrets.DUNE_API_KEY}}
HYPERLIQUID_RPC: ${{ secrets.HYPERLIQUID_RPC }}
PLASMA_RPC: ${{ secrets.PLASMA_RPC }}
STARKNET_RPC: ${{ secrets.STARKNET_RPC }}
MONAD_RPC: ${{ secrets.MONAD_RPC }}
LLAMA_INDEXER_V2_ENDPOINT: ${{ secrets.LLAMA_INDEXER_V2_ENDPOINT }}
LLAMA_INDEXER_V2_API_KEY: ${{ secrets.LLAMA_INDEXER_V2_API_KEY }}
PROJECT_0_API_KEY: ${{ secrets.PROJECT_0_API_KEY }}
23 changes: 14 additions & 9 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,21 @@
name: Test_Change
on:
pull_request
on: pull_request
jobs:
test:
runs-on: ubuntu-latest
steps:
- id: file_changes
uses: trilom/file-changes-action@v1.2.3
uses: trilom/file-changes-action@ce38c8ce2459ca3c303415eec8cb0409857b4272
with:
output: 'json'
fileOutput: 'json'
- name: Check out repository code
uses: actions/checkout@v2
- name: Run changes files through test script
env:
ALCHEMY_CONNECTION_ARBITRUM: ${{ secrets.ALCHEMY_CONNECTION_ARBITRUM }}
ALCHEMY_CONNECTION_ETHEREUM: ${{ secrets.ALCHEMY_CONNECTION_ETHEREUM }}
ALCHEMY_CONNECTION_POLYGON: ${{ secrets.ALCHEMY_CONNECTION_POLYGON }}
run: |
RUN_FILES=$(
MODIFIED=${{ steps.file_changes.outputs.files_modified}} \
Expand All @@ -25,17 +28,19 @@ jobs:
exit 0
fi

npm ci --production --only=prod
npm ci

for i in $(echo $RUN_FILES | tr -d '"[]' | tr "," "\n")
do
{
node ${{ github.workspace }}/src/adaptors/test.js ${{ github.workspace }}/${i} 2>&1 | tee output.txt
do
{
npm run test --adapter=${i} 2>&1 | tee output.txt
node ${{ github.workspace }}/.github/workflows/commentResult.js /home/runner/work/yield-server/yield-server/output.txt "${{ github.repository_owner }}" "${{ github.event.repository.name }}" "${{ github.event.number }}" ${i}
if grep -q "\-\-\-\- ERROR \-\-\-\-" output.txt; then
if grep -q "PASS src/adaptors/test.js" output.txt; then
exit 0;
else
exit 1;
fi
} || {
} || {
echo -n $i
echo ' doesnt run'
}
Expand Down
15 changes: 15 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,18 @@ ccImages
.webpack
.idea/
*output.json
*.csv
scripts/*.json
src/adaptors/list.js
Untitled.ipynb
.ipynb_checkpoints/
yarn-error.log
test.sql
yarn.lock
.test-adapter-output/


src/adaptors/maverick-protocol/
src/adaptors/metavault-v3/
src/adaptors/muuu-finance/navi-lending/
src/adaptors/syncswap/
Empty file modified .prettierrc
100755 → 100644
Empty file.
114 changes: 87 additions & 27 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,102 @@

## How to list a new protocol

1. Fork this repository
2. Create a new folder within [src/adaptors/](src/adaptors/) with your protocol name (use your project `slug` from `https://api.llama.fi/protocols`)
3. Write an adaptor for your protocol (tutorial below)
4. Test your adaptor by running `node src/adaptors/test.js src/adaptors/YOUR_ADAPTOR/index.js` (remember to install dependencies with `npm i` first!)
5. Submit a PR
1. Make sure you are listed on defillama's TVL page (see https://github.com/DefiLlama/DefiLlama-Adapters)
2. Fork this repository
3. Create a new folder within [src/adaptors/](src/adaptors/) with your protocol name (use your project `slug` from `https://api.llama.fi/protocols`)
4. Write an adaptor for your protocol (tutorial below)
5. `cd src/adaptors` and run `npm i`
6. Test your adaptor by running `npm run test --adapter=YOUR_ADAPTER`
7. Submit a PR

### Data sources

The data must be fetched from on-chain calls or from subgraphs. Centralised api calls are only accepted if there is no other way of obtaining that data (eg off-chain gauge weights).

### APY Methodology

Our goal is to display minimum attainable yield values for all listed projects:

- Omit any pre-mined rewards
- Use unboosted (lower bound) apy values
- If rewards are slashed when exiting a pool early, then set the apy value to that lower bound.
- Omit any yield which requires an additional token aside from the LP token (eg veCRV to boost reward yields)
- Omit any locked rewards
- Fee based APY values should be calculated over a 24h window

### Adaptors

An adaptor is just a javascript file that exports an async function that returns an array of objects that represent pools of a protocol. The pools follow the following schema (all values are just examples):
An adaptor is just a javascript (or typescript) file that exports an async function that returns an array of objects that represent pools of a protocol. The pools follow the following schema (all values are just examples):

```typescript
interface Pool {
pool: string;
chain: string;
project: string;
symbol: string;
tvlUsd: number; // for lending protocols: tvlUsd = totalSupplyUsd - totalBorrowUsd
apyBase?: number;
apyReward?: number;
rewardTokens?: Array<string>;
underlyingTokens?: Array<string>;
poolMeta?: string;
url?: string;
// optional lending protocol specific fields:
apyBaseBorrow?: number;
apyRewardBorrow?: number;
totalSupplyUsd?: number;
totalBorrowUsd?: number;
ltv?: number; // btw [0, 1]
}
```

```js
```typescript
{
pool: "0x7fc66500c84a76ad7e9c93437bfc5ac33e2ddae90xb53c1a33016b2dc2ff3653530bff1848a515c8c5", // unique identifier for the pool
chain: "Ethereum", // chain where the pool is
pool: "0x3ed3b47dd13ec9a98b44e6204a523e766b225811-ethereum", // unique identifier for the pool in the form of: `${ReceivedTokenAddress}-${chain}`.toLowerCase()
chain: "Ethereum", // chain where the pool is (needs to match the `name` field in here https://api.llama.fi/chains)
project: 'aave', // protocol (using the slug again)
symbol: "USDT", // symbol of the tokens in pool, can be a single symbol if pool is single-sided or multiple symbols (eg: USDT-ETH) if it's an LP
tvlUsd: 1000.1, // number representing current USD TVL in pool
apy: 1.2, // current APY of the pool in %
apyBase: 0.5, // APY from pool fees/supplying in %
apyReward: 0.7, // APY from pool LM rewards in %
rewardTokens: ['0x7Fc66500c84A76Ad7e9c93437bFc5Ac33E2DDaE9'], // Array of reward token addresses (you can omit this field if a pool doesn't have rewards)
underlyingTokens: ['0xdAC17F958D2ee523a2206206994597C13D831ec7'], // Array of underlying token addresses from a pool, eg here USDT address on ethereum
poolMeta: "V3 market", // A string value which can stand for any specific details of a pool position, market, fee tier, lock duration, specific strategy etc
};
```

```
A note on how to set apy related fields:

- if a pool's apy only consists of a base component, provide `apyBase` and omit `apyReward` (or set to null) [and vice versa]
- if a pool's apy consists of both, provide both fields
- if you are unsure/your data source doesn't contain a detailed breakdown, then provide an `apy` field indicating the total apy and omit the `apyBase` and `apyReward` fields (or set to null)
```

### FAQ

#### Why are some pools missing on DefiLlama which appear on my adapter?

DefiLlama only displays pools with >10k TVL, so pools with less TVL than that will appear on the adapter but not on defillama

#### I'm getting errors when running `npm install`

Make sure you're running the command inside the `src/adaptors` folder, not in the project root folder.

#### Why is X pool missing from https://defillama.com/yields/stablecoins ?

That page has stricter filters than other pages, only pools with >1M TVL and on audited protocols are included there.

### Adapter module structure

```js
module.exports = {
timetravel: false,
apy: apy, // Main function, returns pools
url: 'https://example.com/pools', // Link to page with pools (Only required if you do not provide url's for each pool)
};
```

An example of the most basic adaptor is the following for Anchor on terra:

```js
Expand Down Expand Up @@ -51,23 +126,8 @@ const poolsFunction = async () => {
module.exports = {
timetravel: false,
apy: poolsFunction,
url: 'https://app.anchorprotocol.com/#/earn',
};
```

You can find examples for a bunch of other protocols in the [src/adaptors/](src/adaptors/) folder, and if you have any questions feel free to ask them on [our discord](https://discord.gg/defillama).

## Running the server

This is not needed if you just want to contribute an a new protocol through an adapter, only needed if you want to fork defillama.

### set api keys in config.env

```
ETHERSCAN=
FANTOMSCAN=
POLYGONSCAN=
SNOWTRACE=
ARBISCAN=
OPTIMISM=
INFURA_CONNECTION=
```
You can find examples for a bunch of other protocols in the [src/adaptors/](src/adaptors/) folder, and if you have any questions feel free to ask them on [our discord](https://discord.defillama.com/).
11 changes: 11 additions & 0 deletions babel.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
module.exports = function (api) {
api.cache(true);

return {
"presets": ["@babel/preset-typescript"],
"plugins": [
["@babel/plugin-transform-runtime"]
],
"sourceType": "unambiguous"
};
}
Loading