diff --git a/.changeset/slimy-loops-sit.md b/.changeset/slimy-loops-sit.md new file mode 100644 index 0000000..c4bb9f0 --- /dev/null +++ b/.changeset/slimy-loops-sit.md @@ -0,0 +1,7 @@ +--- +"@aave/graphql": minor +"@aave/client": minor +"@aave/react": minor +--- + +exposed unbacked field on the backend and updated the sdk's schema diff --git a/packages/graphql/schema.graphql b/packages/graphql/schema.graphql index 1a8fe7a..268a7f2 100644 --- a/packages/graphql/schema.graphql +++ b/packages/graphql/schema.graphql @@ -1072,6 +1072,9 @@ type Reserve { """If the reserve can use flash loans on it""" flashLoanEnabled: Boolean! + """The unbacked amount in the reserve""" + unbacked: TokenAmount! + """The interest rate strategy address""" interestRateStrategyAddress: EvmAddress! @@ -2293,4 +2296,4 @@ input WithdrawRequest { """The chain id""" chainId: ChainId! -} \ No newline at end of file +} diff --git a/packages/graphql/src/fragments/reserve.ts b/packages/graphql/src/fragments/reserve.ts index b54ff62..7c07411 100644 --- a/packages/graphql/src/fragments/reserve.ts +++ b/packages/graphql/src/fragments/reserve.ts @@ -318,6 +318,9 @@ export const ReserveFragment = graphql( isFrozen isPaused flashLoanEnabled + unbacked{ + ...TokenAmount + } interestRateStrategyAddress permitSupported supplyInfo { diff --git a/packages/graphql/src/graphql-env.d.ts b/packages/graphql/src/graphql-env.d.ts index fb6d649..d777438 100644 --- a/packages/graphql/src/graphql-env.d.ts +++ b/packages/graphql/src/graphql-env.d.ts @@ -79,7 +79,7 @@ export type introspection_types = { 'RepayErc20Amount': { kind: 'INPUT_OBJECT'; name: 'RepayErc20Amount'; isOneOf: true; inputFields: [{ name: 'exact'; type: { kind: 'SCALAR'; name: 'BigDecimal'; ofType: null; }; defaultValue: null }, { name: 'max'; type: { kind: 'SCALAR'; name: 'AlwaysTrue'; ofType: null; }; defaultValue: null }]; }; 'RepayErc20AmountInput': { kind: 'INPUT_OBJECT'; name: 'RepayErc20AmountInput'; isOneOf: false; inputFields: [{ name: 'currency'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'EvmAddress'; ofType: null; }; }; defaultValue: null }, { name: 'value'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'INPUT_OBJECT'; name: 'RepayErc20Amount'; ofType: null; }; }; defaultValue: null }, { name: 'permitSig'; type: { kind: 'INPUT_OBJECT'; name: 'ERC712Signature'; ofType: null; }; defaultValue: null }]; }; 'RepayRequest': { kind: 'INPUT_OBJECT'; name: 'RepayRequest'; isOneOf: false; inputFields: [{ name: 'market'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'EvmAddress'; ofType: null; }; }; defaultValue: null }, { name: 'amount'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'INPUT_OBJECT'; name: 'RepayAmountInput'; ofType: null; }; }; defaultValue: null }, { name: 'sender'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'EvmAddress'; ofType: null; }; }; defaultValue: null }, { name: 'onBehalfOf'; type: { kind: 'SCALAR'; name: 'EvmAddress'; ofType: null; }; defaultValue: null }, { name: 'chainId'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'ChainId'; ofType: null; }; }; defaultValue: null }]; }; - 'Reserve': { kind: 'OBJECT'; name: 'Reserve'; fields: { 'aToken': { name: 'aToken'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'Currency'; ofType: null; }; } }; 'acceptsNative': { name: 'acceptsNative'; type: { kind: 'OBJECT'; name: 'NativeCurrency'; ofType: null; } }; 'borrowInfo': { name: 'borrowInfo'; type: { kind: 'OBJECT'; name: 'ReserveBorrowInfo'; ofType: null; } }; 'eModeInfo': { name: 'eModeInfo'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'LIST'; name: never; ofType: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'EmodeReserveInfo'; ofType: null; }; }; }; } }; 'flashLoanEnabled': { name: 'flashLoanEnabled'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'Boolean'; ofType: null; }; } }; 'incentives': { name: 'incentives'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'LIST'; name: never; ofType: { kind: 'NON_NULL'; name: never; ofType: { kind: 'UNION'; name: 'ReserveIncentive'; ofType: null; }; }; }; } }; 'interestRateStrategyAddress': { name: 'interestRateStrategyAddress'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'EvmAddress'; ofType: null; }; } }; 'isFrozen': { name: 'isFrozen'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'Boolean'; ofType: null; }; } }; 'isPaused': { name: 'isPaused'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'Boolean'; ofType: null; }; } }; 'isolationModeConfig': { name: 'isolationModeConfig'; type: { kind: 'OBJECT'; name: 'ReserveIsolationModeConfig'; ofType: null; } }; 'market': { name: 'market'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'MarketInfo'; ofType: null; }; } }; 'permitSupported': { name: 'permitSupported'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'Boolean'; ofType: null; }; } }; 'size': { name: 'size'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'TokenAmount'; ofType: null; }; } }; 'supplyInfo': { name: 'supplyInfo'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'ReserveSupplyInfo'; ofType: null; }; } }; 'underlyingToken': { name: 'underlyingToken'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'Currency'; ofType: null; }; } }; 'usdExchangeRate': { name: 'usdExchangeRate'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'BigDecimal'; ofType: null; }; } }; 'usdOracleAddress': { name: 'usdOracleAddress'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'EvmAddress'; ofType: null; }; } }; 'userState': { name: 'userState'; type: { kind: 'OBJECT'; name: 'ReserveUserState'; ofType: null; } }; 'vToken': { name: 'vToken'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'Currency'; ofType: null; }; } }; }; }; + 'Reserve': { kind: 'OBJECT'; name: 'Reserve'; fields: { 'aToken': { name: 'aToken'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'Currency'; ofType: null; }; } }; 'acceptsNative': { name: 'acceptsNative'; type: { kind: 'OBJECT'; name: 'NativeCurrency'; ofType: null; } }; 'borrowInfo': { name: 'borrowInfo'; type: { kind: 'OBJECT'; name: 'ReserveBorrowInfo'; ofType: null; } }; 'eModeInfo': { name: 'eModeInfo'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'LIST'; name: never; ofType: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'EmodeReserveInfo'; ofType: null; }; }; }; } }; 'flashLoanEnabled': { name: 'flashLoanEnabled'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'Boolean'; ofType: null; }; } }; 'incentives': { name: 'incentives'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'LIST'; name: never; ofType: { kind: 'NON_NULL'; name: never; ofType: { kind: 'UNION'; name: 'ReserveIncentive'; ofType: null; }; }; }; } }; 'interestRateStrategyAddress': { name: 'interestRateStrategyAddress'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'EvmAddress'; ofType: null; }; } }; 'isFrozen': { name: 'isFrozen'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'Boolean'; ofType: null; }; } }; 'isPaused': { name: 'isPaused'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'Boolean'; ofType: null; }; } }; 'isolationModeConfig': { name: 'isolationModeConfig'; type: { kind: 'OBJECT'; name: 'ReserveIsolationModeConfig'; ofType: null; } }; 'market': { name: 'market'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'MarketInfo'; ofType: null; }; } }; 'permitSupported': { name: 'permitSupported'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'Boolean'; ofType: null; }; } }; 'size': { name: 'size'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'TokenAmount'; ofType: null; }; } }; 'supplyInfo': { name: 'supplyInfo'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'ReserveSupplyInfo'; ofType: null; }; } }; 'unbacked': { name: 'unbacked'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'TokenAmount'; ofType: null; }; } }; 'underlyingToken': { name: 'underlyingToken'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'Currency'; ofType: null; }; } }; 'usdExchangeRate': { name: 'usdExchangeRate'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'BigDecimal'; ofType: null; }; } }; 'usdOracleAddress': { name: 'usdOracleAddress'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'EvmAddress'; ofType: null; }; } }; 'userState': { name: 'userState'; type: { kind: 'OBJECT'; name: 'ReserveUserState'; ofType: null; } }; 'vToken': { name: 'vToken'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'Currency'; ofType: null; }; } }; }; }; 'ReserveBorrowInfo': { kind: 'OBJECT'; name: 'ReserveBorrowInfo'; fields: { 'apy': { name: 'apy'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'PercentValue'; ofType: null; }; } }; 'availableLiquidity': { name: 'availableLiquidity'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'TokenAmount'; ofType: null; }; } }; 'borrowCap': { name: 'borrowCap'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'TokenAmount'; ofType: null; }; } }; 'borrowCapReached': { name: 'borrowCapReached'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'SCALAR'; name: 'Boolean'; ofType: null; }; } }; 'borrowingState': { name: 'borrowingState'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'ENUM'; name: 'ReserveBorrowingState'; ofType: null; }; } }; 'optimalUsageRate': { name: 'optimalUsageRate'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'PercentValue'; ofType: null; }; } }; 'reserveFactor': { name: 'reserveFactor'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'PercentValue'; ofType: null; }; } }; 'total': { name: 'total'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'TokenAmount'; ofType: null; }; } }; 'utilizationRate': { name: 'utilizationRate'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'PercentValue'; ofType: null; }; } }; 'variableRateSlope1': { name: 'variableRateSlope1'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'PercentValue'; ofType: null; }; } }; 'variableRateSlope2': { name: 'variableRateSlope2'; type: { kind: 'NON_NULL'; name: never; ofType: { kind: 'OBJECT'; name: 'PercentValue'; ofType: null; }; } }; }; }; 'ReserveBorrowingState': { name: 'ReserveBorrowingState'; enumValues: 'ENABLED' | 'DISABLED' | 'USER_EMODE_DISABLED_BORROW'; }; 'ReserveIncentive': { kind: 'UNION'; name: 'ReserveIncentive'; fields: {}; possibleTypes: 'AaveBorrowIncentive' | 'AaveSupplyIncentive' | 'MeritBorrowAndSupplyIncentiveCondition' | 'MeritBorrowIncentive' | 'MeritSupplyIncentive'; };