DefiLlama / yield-server

140 stars 779 forks source link

D2Finance: Add adapter #1520

Closed dunglv-smartosc closed 1 week ago

llamatester commented 3 weeks ago

The d2-finance adapter exports pools:

Test Suites: 1 passed, 1 total Tests: 54 passed, 54 total Snapshots: 0 total Time: 0.273 s Ran all test suites.

Nb of pools: 10

Sample pools:
┌─────────┬───────────────────────────────────────────────────────┬────────────┬──────────────┬────────────────┬────────────────────┬────────────────────┐
│ (index) │                         pool                          │   chain    │   project    │     symbol     │       tvlUsd       │        apy         │
├─────────┼───────────────────────────────────────────────────────┼────────────┼──────────────┼────────────────┼────────────────────┼────────────────────┤
│    0    │ '0x0f76de33a3679a6065d14780618b54584a3907d4-arbitrum' │ 'Arbitrum' │ 'd2-finance' │   'dgnETHv2'   │       787245       │         0          │
│    1    │ '0x27d22eb71f00495eccc89bb02c2b68e6988c6a42-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'ETH++'     │  500463.494395865  │ 142.24236607819773 │
│    2    │ '0xb0730aa7d6e880f901b5d71a971096db56895a0f-arbitrum' │ 'Arbitrum' │ 'd2-finance' │     'iARB'     │   350821.0170086   │         0          │
│    3    │ '0x291344fbaac4fe14632061e4c336fe3b94c52320-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'ARB++'     │ 299185.03542019124 │ 170.03050494371968 │
│    4    │ '0x36b1939adf539a4ac94b57dbad32faecd5bcf4d0-arbitrum' │ 'Arbitrum' │ 'd2-finance' │ 'PlsDAOPlusv2' │     262800.77      │         0          │
│    5    │ '0x34f0fdd80a51dfd8ba42343c20f89217280d760e-arbitrum' │ 'Arbitrum' │ 'd2-finance' │  'Dewhalesv2'  │       250250       │         0          │
│    6    │ '0xd1d64daeed7504ef3eb056aa2d973bd064843a84-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'd2USDC'    │   234540.330024    │         0          │
│    7    │ '0x57f467c9c4639b066f5a4d676cd8ed7d87c1791b-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'GTxD2'     │       59059        │         0          │
│    8    │ '0xab2743a3a2e06d457368e901f5f927f271fa1374-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'GMX++'     │       25730        │         0          │
│    9    │ '0x5f44a7dd0a016a5ec9682df36899a781442caa43-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'dgnARB'    │ 10642.951193884028 │         0          │
└─────────┴───────────────────────────────────────────────────────┴────────────┴──────────────┴────────────────┴────────────────────┴────────────────────┘
slasher125 commented 2 weeks ago

apy is 0 for most pools?

dunglv-smartosc commented 2 weeks ago

apy is 0 for most pools?

Yeah, they are all in their first epoch and havent finished yet. Will have some numbers after their first epoch ends

llamatester commented 2 weeks ago

The d2-finance adapter exports pools:

Test Suites: 1 passed, 1 total Tests: 54 passed, 54 total Snapshots: 0 total Time: 0.276 s Ran all test suites.

Nb of pools: 10

Sample pools:
┌─────────┬───────────────────────────────────────────────────────┬────────────┬──────────────┬────────────────┬────────────────────┬────────────────────┐
│ (index) │                         pool                          │   chain    │   project    │     symbol     │       tvlUsd       │        apy         │
├─────────┼───────────────────────────────────────────────────────┼────────────┼──────────────┼────────────────┼────────────────────┼────────────────────┤
│    0    │ '0x27d22eb71f00495eccc89bb02c2b68e6988c6a42-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'ETH++'     │   801204.821059    │ 132.0732069291772  │
│    1    │ '0x0f76de33a3679a6065d14780618b54584a3907d4-arbitrum' │ 'Arbitrum' │ 'd2-finance' │   'dgnETHv2'   │       789402       │         0          │
│    2    │ '0xb0730aa7d6e880f901b5d71a971096db56895a0f-arbitrum' │ 'Arbitrum' │ 'd2-finance' │     'iARB'     │  358613.11743182   │         0          │
│    3    │ '0x291344fbaac4fe14632061e4c336fe3b94c52320-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'ARB++'     │  305830.246875871  │ 170.03050494371968 │
│    4    │ '0x36b1939adf539a4ac94b57dbad32faecd5bcf4d0-arbitrum' │ 'Arbitrum' │ 'd2-finance' │ 'PlsDAOPlusv2' │     268637.849     │         0          │
│    5    │ '0x34f0fdd80a51dfd8ba42343c20f89217280d760e-arbitrum' │ 'Arbitrum' │ 'd2-finance' │  'Dewhalesv2'  │       250000       │         0          │
│    6    │ '0xd1d64daeed7504ef3eb056aa2d973bd064843a84-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'd2USDC'    │     234306.024     │         0          │
│    7    │ '0x57f467c9c4639b066f5a4d676cd8ed7d87c1791b-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'GTxD2'     │       59000        │         0          │
│    8    │ '0xab2743a3a2e06d457368e901f5f927f271fa1374-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'GMX++'     │       25270        │         0          │
│    9    │ '0x5f44a7dd0a016a5ec9682df36899a781442caa43-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'dgnARB'    │ 10879.342232281082 │         0          │
└─────────┴───────────────────────────────────────────────────────┴────────────┴──────────────┴────────────────┴────────────────────┴────────────────────┘
slasher125 commented 2 weeks ago

apy is 0 for most pools?

Yeah, they are all in their first epoch and havent finished yet. Will have some numbers after their first epoch ends

whats the lock duration for the strategies? pls add that info to poolMeta

dunglv-smartosc commented 2 weeks ago

apy is 0 for most pools?

Yeah, they are all in their first epoch and havent finished yet. Will have some numbers after their first epoch ends

whats the lock duration for the strategies? pls add that info to poolMeta

I've updated it!

llamatester commented 2 weeks ago

The d2-finance adapter exports pools:

Test Suites: 1 passed, 1 total Tests: 54 passed, 54 total Snapshots: 0 total Time: 0.274 s Ran all test suites.

Nb of pools: 10

Sample pools:
┌─────────┬───────────────────────────────────────────────────────┬────────────┬──────────────┬────────────────┬───────────────────┬────────────────────┐
│ (index) │                         pool                          │   chain    │   project    │     symbol     │      tvlUsd       │        apy         │
├─────────┼───────────────────────────────────────────────────────┼────────────┼──────────────┼────────────────┼───────────────────┼────────────────────┤
│    0    │ '0x27d22eb71f00495eccc89bb02c2b68e6988c6a42-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'ETH++'     │ 801009.3270826616 │ 132.0732069291772  │
│    1    │ '0x0f76de33a3679a6065d14780618b54584a3907d4-arbitrum' │ 'Arbitrum' │ 'd2-finance' │   'dgnETHv2'   │      714477       │         0          │
│    2    │ '0xb0730aa7d6e880f901b5d71a971096db56895a0f-arbitrum' │ 'Arbitrum' │ 'd2-finance' │     'iARB'     │  305382.47027644  │         0          │
│    3    │ '0x291344fbaac4fe14632061e4c336fe3b94c52320-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'ARB++'     │  260434.41172774  │ 170.03050494371968 │
│    4    │ '0x34f0fdd80a51dfd8ba42343c20f89217280d760e-arbitrum' │ 'Arbitrum' │ 'd2-finance' │  'Dewhalesv2'  │      249939       │         0          │
│    5    │ '0xd1d64daeed7504ef3eb056aa2d973bd064843a84-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'd2USDC'    │ 234248.853330144  │         0          │
│    6    │ '0x36b1939adf539a4ac94b57dbad32faecd5bcf4d0-arbitrum' │ 'Arbitrum' │ 'd2-finance' │ 'PlsDAOPlusv2' │    228762.658     │         0          │
│    7    │ '0x57f467c9c4639b066f5a4d676cd8ed7d87c1791b-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'GTxD2'     │     58985.604     │         0          │
│    8    │ '0xab2743a3a2e06d457368e901f5f927f271fa1374-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'GMX++'     │       21710       │         0          │
│    9    │ '0x5f44a7dd0a016a5ec9682df36899a781442caa43-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'dgnARB'    │ 9264.469826618786 │         0          │
└─────────┴───────────────────────────────────────────────────────┴────────────┴──────────────┴────────────────┴───────────────────┴────────────────────┘
This adapter contains some pools with <10k TVL, these pools won't be shown in DefiLlama
llamatester commented 2 weeks ago

The d2-finance adapter exports pools:

Test Suites: 1 passed, 1 total Tests: 54 passed, 54 total Snapshots: 0 total Time: 0.27 s Ran all test suites.

Nb of pools: 10

Sample pools:
┌─────────┬───────────────────────────────────────────────────────┬────────────┬──────────────┬────────────────┬───────────────────┬────────────────────┐
│ (index) │                         pool                          │   chain    │   project    │     symbol     │      tvlUsd       │        apy         │
├─────────┼───────────────────────────────────────────────────────┼────────────┼──────────────┼────────────────┼───────────────────┼────────────────────┤
│    0    │ '0x27d22eb71f00495eccc89bb02c2b68e6988c6a42-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'ETH++'     │ 801169.5680468734 │ 132.0732069291772  │
│    1    │ '0x0f76de33a3679a6065d14780618b54584a3907d4-arbitrum' │ 'Arbitrum' │ 'd2-finance' │   'dgnETHv2'   │      716559       │         0          │
│    2    │ '0xb0730aa7d6e880f901b5d71a971096db56895a0f-arbitrum' │ 'Arbitrum' │ 'd2-finance' │     'iARB'     │  306776.2348414   │         0          │
│    3    │ '0x291344fbaac4fe14632061e4c336fe3b94c52320-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'ARB++'     │ 261623.0335049944 │ 170.03050494371968 │
│    4    │ '0x34f0fdd80a51dfd8ba42343c20f89217280d760e-arbitrum' │ 'Arbitrum' │ 'd2-finance' │  'Dewhalesv2'  │      249989       │         0          │
│    5    │ '0xd1d64daeed7504ef3eb056aa2d973bd064843a84-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'd2USDC'    │ 234295.714534944  │         0          │
│    6    │ '0x36b1939adf539a4ac94b57dbad32faecd5bcf4d0-arbitrum' │ 'Arbitrum' │ 'd2-finance' │ 'PlsDAOPlusv2' │     229806.73     │         0          │
│    7    │ '0x57f467c9c4639b066f5a4d676cd8ed7d87c1791b-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'GTxD2'     │     58997.404     │         0          │
│    8    │ '0xab2743a3a2e06d457368e901f5f927f271fa1374-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'GMX++'     │       21640       │         0          │
│    9    │ '0x5f44a7dd0a016a5ec9682df36899a781442caa43-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'dgnARB'    │ 9306.752835678848 │         0          │
└─────────┴───────────────────────────────────────────────────────┴────────────┴──────────────┴────────────────┴───────────────────┴────────────────────┘
This adapter contains some pools with <10k TVL, these pools won't be shown in DefiLlama
slasher125 commented 1 week ago

@dunglv-smartosc poolMeta needs to be part of the apy response object (see readme). also, needs to be significantly shorter to be displayed correctly on the ui)

llamatester commented 1 week ago

The d2-finance adapter exports pools:

Test Suites: 1 passed, 1 total Tests: 54 passed, 54 total Snapshots: 0 total Time: 0.276 s Ran all test suites.

Nb of pools: 10

Sample pools:
┌─────────┬───────────────────────────────────────────────────────┬────────────┬──────────────┬────────────────┬───────────────────┬────────────────────┬─────────────────────────────────────────────────────────────────────────────────────┐
│ (index) │                         pool                          │   chain    │   project    │     symbol     │      tvlUsd       │        apy         │                                      poolMeta                                       │
├─────────┼───────────────────────────────────────────────────────┼────────────┼──────────────┼────────────────┼───────────────────┼────────────────────┼─────────────────────────────────────────────────────────────────────────────────────┤
│    0    │ '0x27d22eb71f00495eccc89bb02c2b68e6988c6a42-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'ETH++'     │ 802006.025880059  │ 132.0732069291772  │ "Strategy's lock duration is aligned with market opportunities, verifable onchain." │
│    1    │ '0x0f76de33a3679a6065d14780618b54584a3907d4-arbitrum' │ 'Arbitrum' │ 'd2-finance' │   'dgnETHv2'   │      726963       │         0          │ "Strategy's lock duration is aligned with market opportunities, verifable onchain." │
│    2    │ '0xb0730aa7d6e880f901b5d71a971096db56895a0f-arbitrum' │ 'Arbitrum' │ 'd2-finance' │     'iARB'     │  323835.04770714  │         0          │ "Strategy's lock duration is aligned with market opportunities, verifable onchain." │
│    3    │ '0x291344fbaac4fe14632061e4c336fe3b94c52320-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'ARB++'     │ 276171.0260254588 │ 170.03050494371968 │ "Strategy's lock duration is aligned with market opportunities, verifable onchain." │
│    4    │ '0x34f0fdd80a51dfd8ba42343c20f89217280d760e-arbitrum' │ 'Arbitrum' │ 'd2-finance' │  'Dewhalesv2'  │      250250       │         0          │ "Strategy's lock duration is aligned with market opportunities, verifable onchain." │
│    5    │ '0x36b1939adf539a4ac94b57dbad32faecd5bcf4d0-arbitrum' │ 'Arbitrum' │ 'd2-finance' │ 'PlsDAOPlusv2' │    242585.523     │         0          │ "Strategy's lock duration is aligned with market opportunities, verifable onchain." │
│    6    │ '0xd1d64daeed7504ef3eb056aa2d973bd064843a84-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'd2USDC'    │   234540.330024   │         0          │ "Strategy's lock duration is aligned with market opportunities, verifable onchain." │
│    7    │ '0x57f467c9c4639b066f5a4d676cd8ed7d87c1791b-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'GTxD2'     │       59059       │         0          │ "Strategy's lock duration is aligned with market opportunities, verifable onchain." │
│    8    │ '0x5f44a7dd0a016a5ec9682df36899a781442caa43-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'dgnARB'    │ 9824.270612418037 │         0          │ "Strategy's lock duration is aligned with market opportunities, verifable onchain." │
│    9    │ '0xab2743a3a2e06d457368e901f5f927f271fa1374-arbitrum' │ 'Arbitrum' │ 'd2-finance' │    'GMX++'     │ 4436.13588438479  │         0          │ "Strategy's lock duration is aligned with market opportunities, verifable onchain." │
└─────────┴───────────────────────────────────────────────────────┴────────────┴──────────────┴────────────────┴───────────────────┴────────────────────┴─────────────────────────────────────────────────────────────────────────────────────┘
This adapter contains some pools with <10k TVL, these pools won't be shown in DefiLlama
dunglv-smartosc commented 1 week ago

@dunglv-smartosc poolMeta needs to be part of the apy response object (see readme). also, needs to be significantly shorter to be displayed correctly on the ui)

I've updated it! Should it be shorter?