@berachain/graphql 0.1.9 → 0.1.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,10 +1,10 @@
1
- "use strict";var y=Object.defineProperty;var M=Object.getOwnPropertyDescriptor;var S=Object.getOwnPropertyNames;var I=Object.prototype.hasOwnProperty;var x=(o,n)=>{for(var a in n)y(o,a,{get:n[a],enumerable:!0})},T=(o,n,a,r)=>{if(n&&typeof n=="object"||typeof n=="function")for(let u of S(n))!I.call(o,u)&&u!==a&&y(o,u,{get:()=>n[u],enumerable:!(r=M(n,u))||r.enumerable});return o};var w=o=>T(y({},"__esModule",{value:!0}),o);var O={};x(O,{ApyFragment:()=>p,ApySide:()=>g,ChainInfoFragment:()=>l,CuratorInfoFragment:()=>m,IdentityResolver:()=>A,Market:()=>V,MarketPositions:()=>v,MarketSummaries:()=>C,MarketSummaryFragment:()=>c,MerklAction:()=>_,SupportedMarketIds:()=>F,TokenCategory:()=>b,TokenInfoFragment:()=>i,Vault:()=>P,VaultPositions:()=>$,VaultProtocol:()=>h,VaultSummaries:()=>f,VaultSummaryFragment:()=>d,VaultType:()=>k,default:()=>E});module.exports=w(O);var t=require("@apollo/client"),g=(a=>(a.Borrow="Borrow",a.Supply="Supply",a))(g||{}),A=(s=>(s.Base="base",s.Ens="ens",s.Farcaster="farcaster",s.Lens="lens",s.Nns="nns",s.Uni="uni",s.World="world",s))(A||{}),_=(a=>(a.Borrow="Borrow",a.Lend="Lend",a))(_||{}),b=(r=>(r.Btc="Btc",r.Eth="Eth",r.Stable="Stable",r))(b||{}),h=(e=>(e.Enzyme="enzyme",e.EulerEarn="euler_earn",e.EulerV2="euler_v2",e.Gearbox="gearbox",e.Lista="lista",e.Mellow="mellow",e.Midas="midas",e.Morpho="morpho",e.Napier="napier",e.Pendle="pendle",e.Reserve="reserve",e.Silo="silo",e.TurtleClub="turtle_club",e))(h||{}),k=(r=>(r.Index="index",r.Lending="lending",r.Staking="staking",r))(k||{}),l=t.gql`
1
+ "use strict";var y=Object.defineProperty;var I=Object.getOwnPropertyDescriptor;var x=Object.getOwnPropertyNames;var T=Object.prototype.hasOwnProperty;var f=(o,n)=>{for(var a in n)y(o,a,{get:n[a],enumerable:!0})},w=(o,n,a,t)=>{if(n&&typeof n=="object"||typeof n=="function")for(let u of x(n))!T.call(o,u)&&u!==a&&y(o,u,{get:()=>n[u],enumerable:!(t=I(n,u))||t.enumerable});return o};var V=o=>w(y({},"__esModule",{value:!0}),o);var B={};f(B,{ApyFragment:()=>p,ApySide:()=>g,ApyTimeframe:()=>A,ChainInfoFragment:()=>l,CuratorInfoFragment:()=>m,Erc4626VaultProtocol:()=>_,IdentityResolver:()=>b,Market:()=>v,MarketPositions:()=>H,MarketSummaries:()=>P,MarketSummaryFragment:()=>c,MerklAction:()=>h,SupportedMarketIds:()=>E,TokenCategory:()=>k,TokenInfoFragment:()=>i,Vault:()=>$,VaultPositions:()=>F,VaultProtocol:()=>M,VaultSummaries:()=>C,VaultSummaryFragment:()=>d,VaultType:()=>S,default:()=>Q});module.exports=V(B);var e=require("@apollo/client"),g=(a=>(a.Borrow="Borrow",a.Supply="Supply",a))(g||{}),A=(t=>(t.OneDay="one_day",t.SevenDays="seven_days",t.ThirtyDays="thirty_days",t))(A||{}),_=(a=>(a.Generic="generic",a.MorphoV1="morpho_v1",a))(_||{}),b=(s=>(s.Base="base",s.Ens="ens",s.Farcaster="farcaster",s.Lens="lens",s.Nns="nns",s.Uni="uni",s.World="world",s))(b||{}),h=(a=>(a.Borrow="Borrow",a.Lend="Lend",a))(h||{}),k=(t=>(t.Btc="Btc",t.Eth="Eth",t.Stable="Stable",t))(k||{}),M=(r=>(r.Enzyme="enzyme",r.EulerEarn="euler_earn",r.EulerV2="euler_v2",r.Gearbox="gearbox",r.Lista="lista",r.Mellow="mellow",r.Midas="midas",r.Morpho="morpho",r.Napier="napier",r.Pendle="pendle",r.Reserve="reserve",r.Silo="silo",r.TurtleClub="turtle_club",r))(M||{}),S=(t=>(t.Index="index",t.Lending="lending",t.Staking="staking",t))(S||{}),l=e.gql`
2
2
  fragment ChainInfoFragment on Chain {
3
3
  id
4
4
  name
5
5
  icon
6
6
  }
7
- `,i=t.gql`
7
+ `,i=e.gql`
8
8
  fragment TokenInfoFragment on Token {
9
9
  address
10
10
  symbol
@@ -12,13 +12,13 @@
12
12
  icon
13
13
  category
14
14
  }
15
- `,m=t.gql`
15
+ `,m=e.gql`
16
16
  fragment CuratorInfoFragment on Curator {
17
17
  name
18
18
  image
19
19
  url
20
20
  }
21
- `,p=t.gql`
21
+ `,p=e.gql`
22
22
  fragment ApyFragment on Apy {
23
23
  base
24
24
  rewards {
@@ -30,7 +30,7 @@
30
30
  total
31
31
  fee
32
32
  }
33
- ${i}`,d=t.gql`
33
+ ${i}`,d=e.gql`
34
34
  fragment VaultSummaryFragment on MorphoVault {
35
35
  chain {
36
36
  ...ChainInfoFragment
@@ -82,7 +82,7 @@
82
82
  ${l}
83
83
  ${i}
84
84
  ${m}
85
- ${p}`,c=t.gql`
85
+ ${p}`,c=e.gql`
86
86
  fragment MarketSummaryFragment on MorphoMarket {
87
87
  chain {
88
88
  ...ChainInfoFragment
@@ -139,7 +139,7 @@ ${p}`,c=t.gql`
139
139
  }
140
140
  ${l}
141
141
  ${i}
142
- ${p}`,f=t.gql`
142
+ ${p}`,C=e.gql`
143
143
  query VaultSummaries($chainIds: [ChainId!]!, $vaultAddresses: [Address!]!) {
144
144
  morphoVaults(
145
145
  where: {chainId_in: $chainIds, vaultAddress_in: $vaultAddresses}
@@ -153,7 +153,7 @@ ${p}`,f=t.gql`
153
153
  }
154
154
  }
155
155
  }
156
- ${d}`,C=t.gql`
156
+ ${d}`,P=e.gql`
157
157
  query MarketSummaries($chainIds: [ChainId!]!, $marketIds: [Hex!]!) {
158
158
  morphoMarkets(
159
159
  where: {chainId_in: $chainIds, marketId_in: $marketIds}
@@ -167,7 +167,7 @@ ${p}`,f=t.gql`
167
167
  }
168
168
  }
169
169
  }
170
- ${c}`,P=t.gql`
170
+ ${c}`,$=e.gql`
171
171
  query Vault($chainId: ChainId!, $vaultAddress: Address!) {
172
172
  morphoVaults(where: {chainId_in: [$chainId], vaultAddress_in: [$vaultAddress]}) {
173
173
  items {
@@ -224,6 +224,12 @@ ${p}`,f=t.gql`
224
224
  raw
225
225
  formatted
226
226
  }
227
+ liquidityInMarket {
228
+ raw
229
+ formatted
230
+ usd
231
+ }
232
+ utilization
227
233
  }
228
234
  enabled
229
235
  position {
@@ -247,7 +253,7 @@ ${p}`,f=t.gql`
247
253
  ${d}
248
254
  ${l}
249
255
  ${i}
250
- ${p}`,V=t.gql`
256
+ ${p}`,v=e.gql`
251
257
  query Market($chainId: ChainId!, $marketId: Hex!) {
252
258
  morphoMarkets(where: {chainId_in: [$chainId], marketId_in: [$marketId]}) {
253
259
  items {
@@ -334,7 +340,7 @@ ${p}`,V=t.gql`
334
340
  ${c}
335
341
  ${i}
336
342
  ${l}
337
- ${m}`,$=t.gql`
343
+ ${m}`,F=e.gql`
338
344
  query VaultPositions($chainIds: [ChainId!]!, $vaultAddresses: [Address!]!, $accountAddress: Address!) {
339
345
  morphoVaultPositions(
340
346
  where: {chainId_in: $chainIds, vaultAddress_in: $vaultAddresses, accountAddress_in: [$accountAddress]}
@@ -362,7 +368,7 @@ ${m}`,$=t.gql`
362
368
  }
363
369
  }
364
370
  }
365
- `,v=t.gql`
371
+ `,H=e.gql`
366
372
  query MarketPositions($chainIds: [ChainId!]!, $marketIds: [Hex!]!, $accountAddress: Address!) {
367
373
  morphoMarketPositions(
368
374
  where: {chainId_in: $chainIds, marketId_in: $marketIds, accountAddress_in: [$accountAddress]}
@@ -405,7 +411,7 @@ ${m}`,$=t.gql`
405
411
  }
406
412
  }
407
413
  }
408
- `,F=t.gql`
414
+ `,E=e.gql`
409
415
  query SupportedMarketIds($chainIds: [ChainId!]!, $vaultAddresses: [Address!]!) {
410
416
  morphoVaults(where: {chainId_in: $chainIds, vaultAddress_in: $vaultAddresses}) {
411
417
  items {
@@ -420,4 +426,4 @@ ${m}`,$=t.gql`
420
426
  }
421
427
  }
422
428
  }
423
- `,H={possibleTypes:{}},E=H;0&&(module.exports={ApyFragment,ApySide,ChainInfoFragment,CuratorInfoFragment,IdentityResolver,Market,MarketPositions,MarketSummaries,MarketSummaryFragment,MerklAction,SupportedMarketIds,TokenCategory,TokenInfoFragment,Vault,VaultPositions,VaultProtocol,VaultSummaries,VaultSummaryFragment,VaultType});
429
+ `,O={possibleTypes:{Erc4626Vault:["GenericErc4626Vault","MorphoVault"]}},Q=O;0&&(module.exports={ApyFragment,ApySide,ApyTimeframe,ChainInfoFragment,CuratorInfoFragment,Erc4626VaultProtocol,IdentityResolver,Market,MarketPositions,MarketSummaries,MarketSummaryFragment,MerklAction,SupportedMarketIds,TokenCategory,TokenInfoFragment,Vault,VaultPositions,VaultProtocol,VaultSummaries,VaultSummaryFragment,VaultType});
@@ -163,6 +163,12 @@ declare enum ApySide {
163
163
  /** APY earned when supplying */
164
164
  Supply = "Supply"
165
165
  }
166
+ /** Timeframe for APY calculations */
167
+ declare enum ApyTimeframe {
168
+ OneDay = "one_day",
169
+ SevenDays = "seven_days",
170
+ ThirtyDays = "thirty_days"
171
+ }
166
172
  /** A blockchain */
167
173
  type Chain = {
168
174
  __typename?: 'Chain';
@@ -192,6 +198,73 @@ type Curator = {
192
198
  /** URL of the curator */
193
199
  url: Scalars['String']['output'];
194
200
  };
201
+ type Erc4626Vault = {
202
+ /** APY earned when supplying to the vault, computed by annualized share price change over the given timeframe */
203
+ apy: Apy;
204
+ /** Underlying asset of the vault */
205
+ asset: Token;
206
+ /** Chain the vault is deployed on */
207
+ chain: Chain;
208
+ /** Decimals of the vault's shares */
209
+ decimals: Scalars['Int']['output'];
210
+ /** Name of the vault */
211
+ name: Scalars['String']['output'];
212
+ /** Symbol of the vault */
213
+ symbol: Scalars['String']['output'];
214
+ /** Total amount of the underlying assets supplied to the vault */
215
+ totalAssets: TokenAmount;
216
+ /** Address of the vault contract */
217
+ vaultAddress: Scalars['Address']['output'];
218
+ };
219
+ type Erc4626VaultApyArgs = {
220
+ timeframe: ApyTimeframe;
221
+ };
222
+ type Erc4626VaultFilter = {
223
+ keys: InputMaybe<Array<Erc4626VaultKey>>;
224
+ };
225
+ type Erc4626VaultKey = {
226
+ /** Chain the vault is deployed on */
227
+ chainId: Scalars['ChainId']['input'];
228
+ /** Protocol the vault is part of */
229
+ protocol: Erc4626VaultProtocol;
230
+ /** Address of the vault contract */
231
+ vaultAddress: Scalars['Address']['input'];
232
+ };
233
+ type Erc4626VaultPage = {
234
+ __typename?: 'Erc4626VaultPage';
235
+ /** The items in the page */
236
+ items: Array<Maybe<Erc4626Vault>>;
237
+ /** Pagination information for the page */
238
+ pageInfo: PageInfo;
239
+ /** Total number of items */
240
+ totalCount: Scalars['Int']['output'];
241
+ };
242
+ declare enum Erc4626VaultProtocol {
243
+ Generic = "generic",
244
+ MorphoV1 = "morpho_v1"
245
+ }
246
+ type GenericErc4626Vault = Erc4626Vault & {
247
+ __typename?: 'GenericErc4626Vault';
248
+ /** APY earned when supplying to the vault */
249
+ apy: Apy;
250
+ /** Underlying asset of the vault */
251
+ asset: Token;
252
+ /** Chain the vault is deployed on */
253
+ chain: Chain;
254
+ /** Decimals of the vault's shares */
255
+ decimals: Scalars['Int']['output'];
256
+ /** Name of the vault */
257
+ name: Scalars['String']['output'];
258
+ /** Symbol of the vault's shares */
259
+ symbol: Scalars['String']['output'];
260
+ /** Total amount of the underlying assets supplied to the vault */
261
+ totalAssets: TokenAmount;
262
+ /** Address of the vault contract */
263
+ vaultAddress: Scalars['Address']['output'];
264
+ };
265
+ type GenericErc4626VaultApyArgs = {
266
+ timeframe: ApyTimeframe;
267
+ };
195
268
  type Identity = {
196
269
  __typename?: 'Identity';
197
270
  aggregate: IdentityResolverOutput;
@@ -457,8 +530,10 @@ type MorphoMarketPositionPage = {
457
530
  totalCount: Scalars['Int']['output'];
458
531
  };
459
532
  /** Morpho vault */
460
- type MorphoVault = {
533
+ type MorphoVault = Erc4626Vault & {
461
534
  __typename?: 'MorphoVault';
535
+ /** APY earned when supplying to the vault */
536
+ apy: Apy;
462
537
  /** Underlying asset of the vault */
463
538
  asset: Token;
464
539
  /** Chain the vault is deployed on */
@@ -483,21 +558,44 @@ type MorphoVault = {
483
558
  ownerAddress: Scalars['Address']['output'];
484
559
  /** Performance fee of the vault, this is the fee that is taken from the vaults profits */
485
560
  performanceFee: Scalars['Float']['output'];
486
- /** APY earned when supplying to the vault (instantaneous) */
561
+ /**
562
+ * APY earned when supplying to the vault
563
+ * @deprecated Use apy(timeframe: one_day) instead
564
+ */
487
565
  supplyApy: Apy;
488
- /** APY earned when supplying to the vault smoothed over 1 day. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 1 day ago. */
566
+ /**
567
+ * APY earned when supplying to the vault smoothed over 1 day. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 1 day ago.
568
+ * @deprecated Use apy(timeframe: one_day) instead
569
+ */
489
570
  supplyApy1d: Apy;
490
- /** APY earned when supplying to the vault smoothed over 7 days. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 7 days ago. */
571
+ /**
572
+ * APY earned when supplying to the vault smoothed over 7 days. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 7 days ago.
573
+ * @deprecated Use apy(timeframe: seven_days) instead
574
+ */
491
575
  supplyApy7d: Apy;
492
- /** APY earned when supplying to the vault smoothed over 30 days. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 30 days ago. */
576
+ /**
577
+ * APY earned when supplying to the vault smoothed over 30 days. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 30 days ago.
578
+ * @deprecated Use apy(timeframe: thirty_days) instead
579
+ */
493
580
  supplyApy30d: Apy;
581
+ /** Symbol of the vault */
582
+ symbol: Scalars['String']['output'];
583
+ /** Total amount of the underlying assets supplied to the vault */
584
+ totalAssets: TokenAmount;
494
585
  /** Total amount of the idle underlying assets (not being borrowed from the vault) */
495
586
  totalLiquidity: TokenAmount;
496
- /** Total amount of the underlying assets supplied to the vault */
587
+ /**
588
+ * Total amount of the underlying assets supplied to the vault
589
+ * @deprecated Use totalAssets instead
590
+ */
497
591
  totalSupplied: TokenAmount;
498
592
  /** Address of the vault contract */
499
593
  vaultAddress: Scalars['Address']['output'];
500
594
  };
595
+ /** Morpho vault */
596
+ type MorphoVaultApyArgs = {
597
+ timeframe: ApyTimeframe;
598
+ };
501
599
  /** Filter for Morpho vaults */
502
600
  type MorphoVaultFilter = {
503
601
  /** Filter for certain chainIds */
@@ -661,6 +759,7 @@ type Query = {
661
759
  aeraVaults: AeraVaultPage;
662
760
  /** Get supported chains (note that not all kits support all chains) */
663
761
  chains: Array<Chain>;
762
+ erc4626Vaults: Erc4626VaultPage;
664
763
  identities: Array<Identity>;
665
764
  identity: Maybe<Identity>;
666
765
  /** Query for Merkl rewards earned on chainId for the accountAddress */
@@ -695,6 +794,12 @@ type QueryAeraVaultsArgs = {
695
794
  type QueryChainsArgs = {
696
795
  where: InputMaybe<ChainFilter>;
697
796
  };
797
+ type QueryErc4626VaultsArgs = {
798
+ after: InputMaybe<Scalars['String']['input']>;
799
+ before: InputMaybe<Scalars['String']['input']>;
800
+ limit: InputMaybe<Scalars['Int']['input']>;
801
+ where: InputMaybe<Erc4626VaultFilter>;
802
+ };
698
803
  type QueryIdentitiesArgs = {
699
804
  addresses: Array<Scalars['Address']['input']>;
700
805
  resolverOrder: InputMaybe<Array<IdentityResolver>>;
@@ -1378,6 +1483,7 @@ type VaultQuery = {
1378
1483
  marketId: `0x${string}`;
1379
1484
  isIdle: boolean;
1380
1485
  name: string;
1486
+ utilization: number;
1381
1487
  chain: {
1382
1488
  __typename?: 'Chain';
1383
1489
  id: 80094;
@@ -1428,6 +1534,12 @@ type VaultQuery = {
1428
1534
  raw: string | bigint;
1429
1535
  formatted: string;
1430
1536
  };
1537
+ liquidityInMarket: {
1538
+ __typename?: 'TokenAmount';
1539
+ raw: string | bigint;
1540
+ formatted: string;
1541
+ usd: number | null;
1542
+ };
1431
1543
  };
1432
1544
  position: {
1433
1545
  __typename?: 'MorphoMarketPosition';
@@ -1799,4 +1911,4 @@ interface PossibleTypesResultData {
1799
1911
  }
1800
1912
  declare const result: PossibleTypesResultData;
1801
1913
 
1802
- export { type AeraVault, type AeraVaultFilter, type AeraVaultPage, type AeraVaultPosition, type AeraVaultPositionFilter, type AeraVaultPositionPage, type Apy, ApyFragment, type ApyFragmentFragment, ApySide, type Chain, type ChainFilter, ChainInfoFragment, type ChainInfoFragmentFragment, type Curator, CuratorInfoFragment, type CuratorInfoFragmentFragment, type Exact, type Identity, IdentityResolver, type IdentityResolverOutput, type Incremental, type InputMaybe, type MakeEmpty, type MakeMaybe, type MakeOptional, Market, MarketPositions, type MarketPositionsQuery, type MarketPositionsQueryVariables, type MarketQuery, type MarketQueryVariables, MarketSummaries, type MarketSummariesQuery, type MarketSummariesQueryVariables, MarketSummaryFragment, type MarketSummaryFragmentFragment, type Maybe, type MerklAccountReward, MerklAction, type MerklRewardInput, type MorphoIrm, type MorphoIrmCurvePoint, type MorphoMarket, type MorphoMarketFilter, type MorphoMarketHistorical, type MorphoMarketHistoricalEntry, type MorphoMarketPage, type MorphoMarketPosition, type MorphoMarketPositionFilter, type MorphoMarketPositionHistorical, type MorphoMarketPositionHistoricalEntry, type MorphoMarketPositionPage, type MorphoVault, type MorphoVaultFilter, type MorphoVaultHistorical, type MorphoVaultHistoricalEntry, type MorphoVaultMarketAllocation, type MorphoVaultMetadata, type MorphoVaultPage, type MorphoVaultPosition, type MorphoVaultPositionFilter, type MorphoVaultPositionHistorical, type MorphoVaultPositionHistoricalEntry, type MorphoVaultPositionPage, type OnchainAmount, type PageInfo, type PossibleTypesResultData, type Protocol, type Query, type QueryAeraVaultPositionsArgs, type QueryAeraVaultsArgs, type QueryChainsArgs, type QueryIdentitiesArgs, type QueryIdentityArgs, type QueryMerklAccountRewardsArgs, type QueryMorphoMarketPositionsArgs, type QueryMorphoMarketsArgs, type QueryMorphoVaultPositionsArgs, type QueryMorphoVaultsArgs, type QueryTokenHoldingsArgs, type QueryTokensArgs, type QueryVaultsArgs, type Reward, type Scalars, SupportedMarketIds, type SupportedMarketIdsQuery, type SupportedMarketIdsQueryVariables, type Token, type TokenAmount, TokenCategory, type TokenHistorical, type TokenHistoricalEntry, type TokenHolding, type TokenHoldingInput, TokenInfoFragment, type TokenInfoFragmentFragment, type TokenInput, Vault, type VaultInput, VaultPositions, type VaultPositionsQuery, type VaultPositionsQueryVariables, VaultProtocol, type VaultQuery, type VaultQueryVariables, VaultSummaries, type VaultSummariesQuery, type VaultSummariesQueryVariables, VaultSummaryFragment, type VaultSummaryFragmentFragment, VaultType, result as default };
1914
+ export { type AeraVault, type AeraVaultFilter, type AeraVaultPage, type AeraVaultPosition, type AeraVaultPositionFilter, type AeraVaultPositionPage, type Apy, ApyFragment, type ApyFragmentFragment, ApySide, ApyTimeframe, type Chain, type ChainFilter, ChainInfoFragment, type ChainInfoFragmentFragment, type Curator, CuratorInfoFragment, type CuratorInfoFragmentFragment, type Erc4626Vault, type Erc4626VaultApyArgs, type Erc4626VaultFilter, type Erc4626VaultKey, type Erc4626VaultPage, Erc4626VaultProtocol, type Exact, type GenericErc4626Vault, type GenericErc4626VaultApyArgs, type Identity, IdentityResolver, type IdentityResolverOutput, type Incremental, type InputMaybe, type MakeEmpty, type MakeMaybe, type MakeOptional, Market, MarketPositions, type MarketPositionsQuery, type MarketPositionsQueryVariables, type MarketQuery, type MarketQueryVariables, MarketSummaries, type MarketSummariesQuery, type MarketSummariesQueryVariables, MarketSummaryFragment, type MarketSummaryFragmentFragment, type Maybe, type MerklAccountReward, MerklAction, type MerklRewardInput, type MorphoIrm, type MorphoIrmCurvePoint, type MorphoMarket, type MorphoMarketFilter, type MorphoMarketHistorical, type MorphoMarketHistoricalEntry, type MorphoMarketPage, type MorphoMarketPosition, type MorphoMarketPositionFilter, type MorphoMarketPositionHistorical, type MorphoMarketPositionHistoricalEntry, type MorphoMarketPositionPage, type MorphoVault, type MorphoVaultApyArgs, type MorphoVaultFilter, type MorphoVaultHistorical, type MorphoVaultHistoricalEntry, type MorphoVaultMarketAllocation, type MorphoVaultMetadata, type MorphoVaultPage, type MorphoVaultPosition, type MorphoVaultPositionFilter, type MorphoVaultPositionHistorical, type MorphoVaultPositionHistoricalEntry, type MorphoVaultPositionPage, type OnchainAmount, type PageInfo, type PossibleTypesResultData, type Protocol, type Query, type QueryAeraVaultPositionsArgs, type QueryAeraVaultsArgs, type QueryChainsArgs, type QueryErc4626VaultsArgs, type QueryIdentitiesArgs, type QueryIdentityArgs, type QueryMerklAccountRewardsArgs, type QueryMorphoMarketPositionsArgs, type QueryMorphoMarketsArgs, type QueryMorphoVaultPositionsArgs, type QueryMorphoVaultsArgs, type QueryTokenHoldingsArgs, type QueryTokensArgs, type QueryVaultsArgs, type Reward, type Scalars, SupportedMarketIds, type SupportedMarketIdsQuery, type SupportedMarketIdsQueryVariables, type Token, type TokenAmount, TokenCategory, type TokenHistorical, type TokenHistoricalEntry, type TokenHolding, type TokenHoldingInput, TokenInfoFragment, type TokenInfoFragmentFragment, type TokenInput, Vault, type VaultInput, VaultPositions, type VaultPositionsQuery, type VaultPositionsQueryVariables, VaultProtocol, type VaultQuery, type VaultQueryVariables, VaultSummaries, type VaultSummariesQuery, type VaultSummariesQueryVariables, VaultSummaryFragment, type VaultSummaryFragmentFragment, VaultType, result as default };
@@ -163,6 +163,12 @@ declare enum ApySide {
163
163
  /** APY earned when supplying */
164
164
  Supply = "Supply"
165
165
  }
166
+ /** Timeframe for APY calculations */
167
+ declare enum ApyTimeframe {
168
+ OneDay = "one_day",
169
+ SevenDays = "seven_days",
170
+ ThirtyDays = "thirty_days"
171
+ }
166
172
  /** A blockchain */
167
173
  type Chain = {
168
174
  __typename?: 'Chain';
@@ -192,6 +198,73 @@ type Curator = {
192
198
  /** URL of the curator */
193
199
  url: Scalars['String']['output'];
194
200
  };
201
+ type Erc4626Vault = {
202
+ /** APY earned when supplying to the vault, computed by annualized share price change over the given timeframe */
203
+ apy: Apy;
204
+ /** Underlying asset of the vault */
205
+ asset: Token;
206
+ /** Chain the vault is deployed on */
207
+ chain: Chain;
208
+ /** Decimals of the vault's shares */
209
+ decimals: Scalars['Int']['output'];
210
+ /** Name of the vault */
211
+ name: Scalars['String']['output'];
212
+ /** Symbol of the vault */
213
+ symbol: Scalars['String']['output'];
214
+ /** Total amount of the underlying assets supplied to the vault */
215
+ totalAssets: TokenAmount;
216
+ /** Address of the vault contract */
217
+ vaultAddress: Scalars['Address']['output'];
218
+ };
219
+ type Erc4626VaultApyArgs = {
220
+ timeframe: ApyTimeframe;
221
+ };
222
+ type Erc4626VaultFilter = {
223
+ keys: InputMaybe<Array<Erc4626VaultKey>>;
224
+ };
225
+ type Erc4626VaultKey = {
226
+ /** Chain the vault is deployed on */
227
+ chainId: Scalars['ChainId']['input'];
228
+ /** Protocol the vault is part of */
229
+ protocol: Erc4626VaultProtocol;
230
+ /** Address of the vault contract */
231
+ vaultAddress: Scalars['Address']['input'];
232
+ };
233
+ type Erc4626VaultPage = {
234
+ __typename?: 'Erc4626VaultPage';
235
+ /** The items in the page */
236
+ items: Array<Maybe<Erc4626Vault>>;
237
+ /** Pagination information for the page */
238
+ pageInfo: PageInfo;
239
+ /** Total number of items */
240
+ totalCount: Scalars['Int']['output'];
241
+ };
242
+ declare enum Erc4626VaultProtocol {
243
+ Generic = "generic",
244
+ MorphoV1 = "morpho_v1"
245
+ }
246
+ type GenericErc4626Vault = Erc4626Vault & {
247
+ __typename?: 'GenericErc4626Vault';
248
+ /** APY earned when supplying to the vault */
249
+ apy: Apy;
250
+ /** Underlying asset of the vault */
251
+ asset: Token;
252
+ /** Chain the vault is deployed on */
253
+ chain: Chain;
254
+ /** Decimals of the vault's shares */
255
+ decimals: Scalars['Int']['output'];
256
+ /** Name of the vault */
257
+ name: Scalars['String']['output'];
258
+ /** Symbol of the vault's shares */
259
+ symbol: Scalars['String']['output'];
260
+ /** Total amount of the underlying assets supplied to the vault */
261
+ totalAssets: TokenAmount;
262
+ /** Address of the vault contract */
263
+ vaultAddress: Scalars['Address']['output'];
264
+ };
265
+ type GenericErc4626VaultApyArgs = {
266
+ timeframe: ApyTimeframe;
267
+ };
195
268
  type Identity = {
196
269
  __typename?: 'Identity';
197
270
  aggregate: IdentityResolverOutput;
@@ -457,8 +530,10 @@ type MorphoMarketPositionPage = {
457
530
  totalCount: Scalars['Int']['output'];
458
531
  };
459
532
  /** Morpho vault */
460
- type MorphoVault = {
533
+ type MorphoVault = Erc4626Vault & {
461
534
  __typename?: 'MorphoVault';
535
+ /** APY earned when supplying to the vault */
536
+ apy: Apy;
462
537
  /** Underlying asset of the vault */
463
538
  asset: Token;
464
539
  /** Chain the vault is deployed on */
@@ -483,21 +558,44 @@ type MorphoVault = {
483
558
  ownerAddress: Scalars['Address']['output'];
484
559
  /** Performance fee of the vault, this is the fee that is taken from the vaults profits */
485
560
  performanceFee: Scalars['Float']['output'];
486
- /** APY earned when supplying to the vault (instantaneous) */
561
+ /**
562
+ * APY earned when supplying to the vault
563
+ * @deprecated Use apy(timeframe: one_day) instead
564
+ */
487
565
  supplyApy: Apy;
488
- /** APY earned when supplying to the vault smoothed over 1 day. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 1 day ago. */
566
+ /**
567
+ * APY earned when supplying to the vault smoothed over 1 day. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 1 day ago.
568
+ * @deprecated Use apy(timeframe: one_day) instead
569
+ */
489
570
  supplyApy1d: Apy;
490
- /** APY earned when supplying to the vault smoothed over 7 days. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 7 days ago. */
571
+ /**
572
+ * APY earned when supplying to the vault smoothed over 7 days. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 7 days ago.
573
+ * @deprecated Use apy(timeframe: seven_days) instead
574
+ */
491
575
  supplyApy7d: Apy;
492
- /** APY earned when supplying to the vault smoothed over 30 days. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 30 days ago. */
576
+ /**
577
+ * APY earned when supplying to the vault smoothed over 30 days. Note rewards are instantaneous, and base is instantaneous when the vault has been deployed less than 30 days ago.
578
+ * @deprecated Use apy(timeframe: thirty_days) instead
579
+ */
493
580
  supplyApy30d: Apy;
581
+ /** Symbol of the vault */
582
+ symbol: Scalars['String']['output'];
583
+ /** Total amount of the underlying assets supplied to the vault */
584
+ totalAssets: TokenAmount;
494
585
  /** Total amount of the idle underlying assets (not being borrowed from the vault) */
495
586
  totalLiquidity: TokenAmount;
496
- /** Total amount of the underlying assets supplied to the vault */
587
+ /**
588
+ * Total amount of the underlying assets supplied to the vault
589
+ * @deprecated Use totalAssets instead
590
+ */
497
591
  totalSupplied: TokenAmount;
498
592
  /** Address of the vault contract */
499
593
  vaultAddress: Scalars['Address']['output'];
500
594
  };
595
+ /** Morpho vault */
596
+ type MorphoVaultApyArgs = {
597
+ timeframe: ApyTimeframe;
598
+ };
501
599
  /** Filter for Morpho vaults */
502
600
  type MorphoVaultFilter = {
503
601
  /** Filter for certain chainIds */
@@ -661,6 +759,7 @@ type Query = {
661
759
  aeraVaults: AeraVaultPage;
662
760
  /** Get supported chains (note that not all kits support all chains) */
663
761
  chains: Array<Chain>;
762
+ erc4626Vaults: Erc4626VaultPage;
664
763
  identities: Array<Identity>;
665
764
  identity: Maybe<Identity>;
666
765
  /** Query for Merkl rewards earned on chainId for the accountAddress */
@@ -695,6 +794,12 @@ type QueryAeraVaultsArgs = {
695
794
  type QueryChainsArgs = {
696
795
  where: InputMaybe<ChainFilter>;
697
796
  };
797
+ type QueryErc4626VaultsArgs = {
798
+ after: InputMaybe<Scalars['String']['input']>;
799
+ before: InputMaybe<Scalars['String']['input']>;
800
+ limit: InputMaybe<Scalars['Int']['input']>;
801
+ where: InputMaybe<Erc4626VaultFilter>;
802
+ };
698
803
  type QueryIdentitiesArgs = {
699
804
  addresses: Array<Scalars['Address']['input']>;
700
805
  resolverOrder: InputMaybe<Array<IdentityResolver>>;
@@ -1378,6 +1483,7 @@ type VaultQuery = {
1378
1483
  marketId: `0x${string}`;
1379
1484
  isIdle: boolean;
1380
1485
  name: string;
1486
+ utilization: number;
1381
1487
  chain: {
1382
1488
  __typename?: 'Chain';
1383
1489
  id: 80094;
@@ -1428,6 +1534,12 @@ type VaultQuery = {
1428
1534
  raw: string | bigint;
1429
1535
  formatted: string;
1430
1536
  };
1537
+ liquidityInMarket: {
1538
+ __typename?: 'TokenAmount';
1539
+ raw: string | bigint;
1540
+ formatted: string;
1541
+ usd: number | null;
1542
+ };
1431
1543
  };
1432
1544
  position: {
1433
1545
  __typename?: 'MorphoMarketPosition';
@@ -1799,4 +1911,4 @@ interface PossibleTypesResultData {
1799
1911
  }
1800
1912
  declare const result: PossibleTypesResultData;
1801
1913
 
1802
- export { type AeraVault, type AeraVaultFilter, type AeraVaultPage, type AeraVaultPosition, type AeraVaultPositionFilter, type AeraVaultPositionPage, type Apy, ApyFragment, type ApyFragmentFragment, ApySide, type Chain, type ChainFilter, ChainInfoFragment, type ChainInfoFragmentFragment, type Curator, CuratorInfoFragment, type CuratorInfoFragmentFragment, type Exact, type Identity, IdentityResolver, type IdentityResolverOutput, type Incremental, type InputMaybe, type MakeEmpty, type MakeMaybe, type MakeOptional, Market, MarketPositions, type MarketPositionsQuery, type MarketPositionsQueryVariables, type MarketQuery, type MarketQueryVariables, MarketSummaries, type MarketSummariesQuery, type MarketSummariesQueryVariables, MarketSummaryFragment, type MarketSummaryFragmentFragment, type Maybe, type MerklAccountReward, MerklAction, type MerklRewardInput, type MorphoIrm, type MorphoIrmCurvePoint, type MorphoMarket, type MorphoMarketFilter, type MorphoMarketHistorical, type MorphoMarketHistoricalEntry, type MorphoMarketPage, type MorphoMarketPosition, type MorphoMarketPositionFilter, type MorphoMarketPositionHistorical, type MorphoMarketPositionHistoricalEntry, type MorphoMarketPositionPage, type MorphoVault, type MorphoVaultFilter, type MorphoVaultHistorical, type MorphoVaultHistoricalEntry, type MorphoVaultMarketAllocation, type MorphoVaultMetadata, type MorphoVaultPage, type MorphoVaultPosition, type MorphoVaultPositionFilter, type MorphoVaultPositionHistorical, type MorphoVaultPositionHistoricalEntry, type MorphoVaultPositionPage, type OnchainAmount, type PageInfo, type PossibleTypesResultData, type Protocol, type Query, type QueryAeraVaultPositionsArgs, type QueryAeraVaultsArgs, type QueryChainsArgs, type QueryIdentitiesArgs, type QueryIdentityArgs, type QueryMerklAccountRewardsArgs, type QueryMorphoMarketPositionsArgs, type QueryMorphoMarketsArgs, type QueryMorphoVaultPositionsArgs, type QueryMorphoVaultsArgs, type QueryTokenHoldingsArgs, type QueryTokensArgs, type QueryVaultsArgs, type Reward, type Scalars, SupportedMarketIds, type SupportedMarketIdsQuery, type SupportedMarketIdsQueryVariables, type Token, type TokenAmount, TokenCategory, type TokenHistorical, type TokenHistoricalEntry, type TokenHolding, type TokenHoldingInput, TokenInfoFragment, type TokenInfoFragmentFragment, type TokenInput, Vault, type VaultInput, VaultPositions, type VaultPositionsQuery, type VaultPositionsQueryVariables, VaultProtocol, type VaultQuery, type VaultQueryVariables, VaultSummaries, type VaultSummariesQuery, type VaultSummariesQueryVariables, VaultSummaryFragment, type VaultSummaryFragmentFragment, VaultType, result as default };
1914
+ export { type AeraVault, type AeraVaultFilter, type AeraVaultPage, type AeraVaultPosition, type AeraVaultPositionFilter, type AeraVaultPositionPage, type Apy, ApyFragment, type ApyFragmentFragment, ApySide, ApyTimeframe, type Chain, type ChainFilter, ChainInfoFragment, type ChainInfoFragmentFragment, type Curator, CuratorInfoFragment, type CuratorInfoFragmentFragment, type Erc4626Vault, type Erc4626VaultApyArgs, type Erc4626VaultFilter, type Erc4626VaultKey, type Erc4626VaultPage, Erc4626VaultProtocol, type Exact, type GenericErc4626Vault, type GenericErc4626VaultApyArgs, type Identity, IdentityResolver, type IdentityResolverOutput, type Incremental, type InputMaybe, type MakeEmpty, type MakeMaybe, type MakeOptional, Market, MarketPositions, type MarketPositionsQuery, type MarketPositionsQueryVariables, type MarketQuery, type MarketQueryVariables, MarketSummaries, type MarketSummariesQuery, type MarketSummariesQueryVariables, MarketSummaryFragment, type MarketSummaryFragmentFragment, type Maybe, type MerklAccountReward, MerklAction, type MerklRewardInput, type MorphoIrm, type MorphoIrmCurvePoint, type MorphoMarket, type MorphoMarketFilter, type MorphoMarketHistorical, type MorphoMarketHistoricalEntry, type MorphoMarketPage, type MorphoMarketPosition, type MorphoMarketPositionFilter, type MorphoMarketPositionHistorical, type MorphoMarketPositionHistoricalEntry, type MorphoMarketPositionPage, type MorphoVault, type MorphoVaultApyArgs, type MorphoVaultFilter, type MorphoVaultHistorical, type MorphoVaultHistoricalEntry, type MorphoVaultMarketAllocation, type MorphoVaultMetadata, type MorphoVaultPage, type MorphoVaultPosition, type MorphoVaultPositionFilter, type MorphoVaultPositionHistorical, type MorphoVaultPositionHistoricalEntry, type MorphoVaultPositionPage, type OnchainAmount, type PageInfo, type PossibleTypesResultData, type Protocol, type Query, type QueryAeraVaultPositionsArgs, type QueryAeraVaultsArgs, type QueryChainsArgs, type QueryErc4626VaultsArgs, type QueryIdentitiesArgs, type QueryIdentityArgs, type QueryMerklAccountRewardsArgs, type QueryMorphoMarketPositionsArgs, type QueryMorphoMarketsArgs, type QueryMorphoVaultPositionsArgs, type QueryMorphoVaultsArgs, type QueryTokenHoldingsArgs, type QueryTokensArgs, type QueryVaultsArgs, type Reward, type Scalars, SupportedMarketIds, type SupportedMarketIdsQuery, type SupportedMarketIdsQueryVariables, type Token, type TokenAmount, TokenCategory, type TokenHistorical, type TokenHistoricalEntry, type TokenHolding, type TokenHoldingInput, TokenInfoFragment, type TokenInfoFragmentFragment, type TokenInput, Vault, type VaultInput, VaultPositions, type VaultPositionsQuery, type VaultPositionsQueryVariables, VaultProtocol, type VaultQuery, type VaultQueryVariables, VaultSummaries, type VaultSummariesQuery, type VaultSummariesQueryVariables, VaultSummaryFragment, type VaultSummaryFragmentFragment, VaultType, result as default };
@@ -1,4 +1,4 @@
1
- import{gql as e}from"@apollo/client";var y=(n=>(n.Borrow="Borrow",n.Supply="Supply",n))(y||{}),m=(r=>(r.Base="base",r.Ens="ens",r.Farcaster="farcaster",r.Lens="lens",r.Nns="nns",r.Uni="uni",r.World="world",r))(m||{}),d=(n=>(n.Borrow="Borrow",n.Lend="Lend",n))(d||{}),c=(a=>(a.Btc="Btc",a.Eth="Eth",a.Stable="Stable",a))(c||{}),g=(t=>(t.Enzyme="enzyme",t.EulerEarn="euler_earn",t.EulerV2="euler_v2",t.Gearbox="gearbox",t.Lista="lista",t.Mellow="mellow",t.Midas="midas",t.Morpho="morpho",t.Napier="napier",t.Pendle="pendle",t.Reserve="reserve",t.Silo="silo",t.TurtleClub="turtle_club",t))(g||{}),A=(a=>(a.Index="index",a.Lending="lending",a.Staking="staking",a))(A||{}),s=e`
1
+ import{gql as e}from"@apollo/client";var y=(r=>(r.Borrow="Borrow",r.Supply="Supply",r))(y||{}),m=(a=>(a.OneDay="one_day",a.SevenDays="seven_days",a.ThirtyDays="thirty_days",a))(m||{}),d=(r=>(r.Generic="generic",r.MorphoV1="morpho_v1",r))(d||{}),c=(n=>(n.Base="base",n.Ens="ens",n.Farcaster="farcaster",n.Lens="lens",n.Nns="nns",n.Uni="uni",n.World="world",n))(c||{}),g=(r=>(r.Borrow="Borrow",r.Lend="Lend",r))(g||{}),A=(a=>(a.Btc="Btc",a.Eth="Eth",a.Stable="Stable",a))(A||{}),_=(t=>(t.Enzyme="enzyme",t.EulerEarn="euler_earn",t.EulerV2="euler_v2",t.Gearbox="gearbox",t.Lista="lista",t.Mellow="mellow",t.Midas="midas",t.Morpho="morpho",t.Napier="napier",t.Pendle="pendle",t.Reserve="reserve",t.Silo="silo",t.TurtleClub="turtle_club",t))(_||{}),b=(a=>(a.Index="index",a.Lending="lending",a.Staking="staking",a))(b||{}),s=e`
2
2
  fragment ChainInfoFragment on Chain {
3
3
  id
4
4
  name
@@ -139,7 +139,7 @@ ${i}`,p=e`
139
139
  }
140
140
  ${s}
141
141
  ${o}
142
- ${i}`,h=e`
142
+ ${i}`,M=e`
143
143
  query VaultSummaries($chainIds: [ChainId!]!, $vaultAddresses: [Address!]!) {
144
144
  morphoVaults(
145
145
  where: {chainId_in: $chainIds, vaultAddress_in: $vaultAddresses}
@@ -153,7 +153,7 @@ ${i}`,h=e`
153
153
  }
154
154
  }
155
155
  }
156
- ${l}`,k=e`
156
+ ${l}`,S=e`
157
157
  query MarketSummaries($chainIds: [ChainId!]!, $marketIds: [Hex!]!) {
158
158
  morphoMarkets(
159
159
  where: {chainId_in: $chainIds, marketId_in: $marketIds}
@@ -167,7 +167,7 @@ ${i}`,h=e`
167
167
  }
168
168
  }
169
169
  }
170
- ${p}`,M=e`
170
+ ${p}`,I=e`
171
171
  query Vault($chainId: ChainId!, $vaultAddress: Address!) {
172
172
  morphoVaults(where: {chainId_in: [$chainId], vaultAddress_in: [$vaultAddress]}) {
173
173
  items {
@@ -224,6 +224,12 @@ ${i}`,h=e`
224
224
  raw
225
225
  formatted
226
226
  }
227
+ liquidityInMarket {
228
+ raw
229
+ formatted
230
+ usd
231
+ }
232
+ utilization
227
233
  }
228
234
  enabled
229
235
  position {
@@ -247,7 +253,7 @@ ${i}`,h=e`
247
253
  ${l}
248
254
  ${s}
249
255
  ${o}
250
- ${i}`,S=e`
256
+ ${i}`,x=e`
251
257
  query Market($chainId: ChainId!, $marketId: Hex!) {
252
258
  morphoMarkets(where: {chainId_in: [$chainId], marketId_in: [$marketId]}) {
253
259
  items {
@@ -334,7 +340,7 @@ ${i}`,S=e`
334
340
  ${p}
335
341
  ${o}
336
342
  ${s}
337
- ${u}`,I=e`
343
+ ${u}`,T=e`
338
344
  query VaultPositions($chainIds: [ChainId!]!, $vaultAddresses: [Address!]!, $accountAddress: Address!) {
339
345
  morphoVaultPositions(
340
346
  where: {chainId_in: $chainIds, vaultAddress_in: $vaultAddresses, accountAddress_in: [$accountAddress]}
@@ -362,7 +368,7 @@ ${u}`,I=e`
362
368
  }
363
369
  }
364
370
  }
365
- `,x=e`
371
+ `,f=e`
366
372
  query MarketPositions($chainIds: [ChainId!]!, $marketIds: [Hex!]!, $accountAddress: Address!) {
367
373
  morphoMarketPositions(
368
374
  where: {chainId_in: $chainIds, marketId_in: $marketIds, accountAddress_in: [$accountAddress]}
@@ -405,7 +411,7 @@ ${u}`,I=e`
405
411
  }
406
412
  }
407
413
  }
408
- `,T=e`
414
+ `,w=e`
409
415
  query SupportedMarketIds($chainIds: [ChainId!]!, $vaultAddresses: [Address!]!) {
410
416
  morphoVaults(where: {chainId_in: $chainIds, vaultAddress_in: $vaultAddresses}) {
411
417
  items {
@@ -420,4 +426,4 @@ ${u}`,I=e`
420
426
  }
421
427
  }
422
428
  }
423
- `,_={possibleTypes:{}},w=_;export{i as ApyFragment,y as ApySide,s as ChainInfoFragment,u as CuratorInfoFragment,m as IdentityResolver,S as Market,x as MarketPositions,k as MarketSummaries,p as MarketSummaryFragment,d as MerklAction,T as SupportedMarketIds,c as TokenCategory,o as TokenInfoFragment,M as Vault,I as VaultPositions,g as VaultProtocol,h as VaultSummaries,l as VaultSummaryFragment,A as VaultType,w as default};
429
+ `,h={possibleTypes:{Erc4626Vault:["GenericErc4626Vault","MorphoVault"]}},V=h;export{i as ApyFragment,y as ApySide,m as ApyTimeframe,s as ChainInfoFragment,u as CuratorInfoFragment,d as Erc4626VaultProtocol,c as IdentityResolver,x as Market,f as MarketPositions,S as MarketSummaries,p as MarketSummaryFragment,g as MerklAction,w as SupportedMarketIds,A as TokenCategory,o as TokenInfoFragment,I as Vault,T as VaultPositions,_ as VaultProtocol,M as VaultSummaries,l as VaultSummaryFragment,b as VaultType,V as default};