@berachain/berajs 0.2.13 → 0.3.1

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.
Files changed (387) hide show
  1. package/dist/actions/clients/BeraApolloClient.d.ts.map +1 -1
  2. package/dist/actions/clients/clientName.d.ts +10 -0
  3. package/dist/actions/clients/clientName.d.ts.map +1 -0
  4. package/dist/actions/clients/clientName.unit.test.d.ts +2 -0
  5. package/dist/actions/clients/clientName.unit.test.d.ts.map +1 -0
  6. package/dist/actions/clients/exports.d.ts +2 -0
  7. package/dist/actions/clients/exports.d.ts.map +1 -1
  8. package/dist/actions/clients/exports.mjs +26 -7
  9. package/dist/actions/clients/exports.mjs.map +1 -1
  10. package/dist/actions/clients/fetchBeep.d.ts +2 -2
  11. package/dist/actions/clients/fetchBeep.d.ts.map +1 -1
  12. package/dist/actions/clients/fetchEnso.d.ts +17 -0
  13. package/dist/actions/clients/fetchEnso.d.ts.map +1 -0
  14. package/dist/actions/clients/fetchLayerzero.d.ts +12 -0
  15. package/dist/actions/clients/fetchLayerzero.d.ts.map +1 -0
  16. package/dist/actions/clients/fetchOpenApi.d.ts +4 -1
  17. package/dist/actions/clients/fetchOpenApi.d.ts.map +1 -1
  18. package/dist/actions/clients/getApolloClient.d.ts.map +1 -1
  19. package/dist/actions/dex/aggregators/base.d.ts +30 -5
  20. package/dist/actions/dex/aggregators/base.d.ts.map +1 -1
  21. package/dist/actions/dex/aggregators/bex.d.ts +11 -1
  22. package/dist/actions/dex/aggregators/bex.d.ts.map +1 -1
  23. package/dist/actions/dex/aggregators/bgt.d.ts +2 -2
  24. package/dist/actions/dex/aggregators/bgt.d.ts.map +1 -1
  25. package/dist/actions/dex/aggregators/enso/enso.d.ts.map +1 -1
  26. package/dist/actions/dex/aggregators/enso/ensoErc4626.d.ts +1 -0
  27. package/dist/actions/dex/aggregators/enso/ensoErc4626.d.ts.map +1 -1
  28. package/dist/actions/dex/aggregators/erc4626.d.ts +2 -2
  29. package/dist/actions/dex/aggregators/erc4626.d.ts.map +1 -1
  30. package/dist/actions/dex/aggregators/fly.d.ts.map +1 -1
  31. package/dist/actions/dex/aggregators/haiku.d.ts +7 -1
  32. package/dist/actions/dex/aggregators/haiku.d.ts.map +1 -1
  33. package/dist/actions/dex/aggregators/honey.d.ts +2 -2
  34. package/dist/actions/dex/aggregators/honey.d.ts.map +1 -1
  35. package/dist/actions/dex/aggregators/kyberswap.d.ts.map +1 -1
  36. package/dist/actions/dex/aggregators/oogabooga.d.ts.map +1 -1
  37. package/dist/actions/dex/aggregators/openOcean.d.ts.map +1 -1
  38. package/dist/actions/dex/aggregators/wbera.d.ts +3 -2
  39. package/dist/actions/dex/aggregators/wbera.d.ts.map +1 -1
  40. package/dist/actions/dex/getAllPools.d.ts.map +1 -1
  41. package/dist/actions/dex/getApiPool.d.ts.map +1 -1
  42. package/dist/actions/enso/getEnsoUserTokensWithBalances.d.ts.map +1 -1
  43. package/dist/actions/enso/util.d.ts +1 -6
  44. package/dist/actions/enso/util.d.ts.map +1 -1
  45. package/dist/actions/exports.d.ts +3 -5
  46. package/dist/actions/exports.d.ts.map +1 -1
  47. package/dist/actions/exports.mjs +33 -64
  48. package/dist/actions/exports.mjs.map +1 -1
  49. package/dist/actions/governance/exports.mjs +3 -3
  50. package/dist/actions/honey/getChartData.d.ts +1 -1
  51. package/dist/actions/honey/getChartData.d.ts.map +1 -1
  52. package/dist/actions/honey/getHoney24hVolume.d.ts +2 -2
  53. package/dist/actions/honey/getHoney24hVolume.d.ts.map +1 -1
  54. package/dist/actions/honey/getHoneyCollaterals.d.ts +1 -1
  55. package/dist/actions/honey/getHoneyCollaterals.d.ts.map +1 -1
  56. package/dist/actions/honey/getHoneyTxns.d.ts +1 -1
  57. package/dist/actions/honey/getHoneyTxns.d.ts.map +1 -1
  58. package/dist/actions/pol/getBGTGlobalInfo.d.ts +0 -1
  59. package/dist/actions/pol/getBGTGlobalInfo.d.ts.map +1 -1
  60. package/dist/actions/pol/getBeraTokenTotalSupply.d.ts.map +1 -1
  61. package/dist/actions/pol/getEarnedStakedBeraVault.d.ts +4 -27
  62. package/dist/actions/pol/getEarnedStakedBeraVault.d.ts.map +1 -1
  63. package/dist/actions/pol/getLSTStakeConfig.d.ts.map +1 -1
  64. package/dist/actions/pol/getRewardVaults.d.ts.map +1 -1
  65. package/dist/actions/pol/getSWBeraVaultMetadata.d.ts +1 -14
  66. package/dist/actions/pol/getSWBeraVaultMetadata.d.ts.map +1 -1
  67. package/dist/actions/pol/getStakedBeraAPY.d.ts +14 -0
  68. package/dist/actions/pol/getStakedBeraAPY.d.ts.map +1 -0
  69. package/dist/actions/pol/getStakedBeraSnapshots.d.ts +14 -4
  70. package/dist/actions/pol/getStakedBeraSnapshots.d.ts.map +1 -1
  71. package/dist/actions/pol/getStakingDailyAssets.d.ts +2 -2
  72. package/dist/actions/pol/getStakingDailyAssets.d.ts.map +1 -1
  73. package/dist/actions/server/exports.mjs +5 -5
  74. package/dist/actions/server/exports.mjs.map +1 -1
  75. package/dist/actions/server/getDailyValidatorBlockStats.d.ts +1 -1
  76. package/dist/actions/server/getDailyValidatorBlockStats.d.ts.map +1 -1
  77. package/dist/actions/validators/getActiveBoostAndCommissionChangeDelay.d.ts +1 -1
  78. package/dist/actions/validators/getActiveBoostAndCommissionChangeDelay.d.ts.map +1 -1
  79. package/dist/actions/validators/getUserActiveValidators.d.ts +37 -1
  80. package/dist/actions/validators/getUserActiveValidators.d.ts.map +1 -1
  81. package/dist/actions/validators/getValidatorIncentiveDistribution.d.ts +1 -1
  82. package/dist/actions/validators/getValidatorIncentiveDistribution.d.ts.map +1 -1
  83. package/dist/actions/validators/getValidatorRewardAllocation.d.ts +4 -0
  84. package/dist/actions/validators/getValidatorRewardAllocation.d.ts.map +1 -1
  85. package/dist/chunk-3TRTSTDH.mjs +19 -0
  86. package/dist/chunk-3TRTSTDH.mjs.map +1 -0
  87. package/dist/{chunk-ZWTGVIPJ.mjs → chunk-4576RF2K.mjs} +29 -4
  88. package/dist/chunk-4576RF2K.mjs.map +1 -0
  89. package/dist/{chunk-PHYZRH4I.mjs → chunk-5MUCX35C.mjs} +9 -13
  90. package/dist/chunk-5MUCX35C.mjs.map +1 -0
  91. package/dist/{chunk-UA3Z47LT.mjs → chunk-6D4S3EAC.mjs} +97 -26
  92. package/dist/chunk-6D4S3EAC.mjs.map +1 -0
  93. package/dist/{chunk-AEN6IJFU.mjs → chunk-7KN7TDUC.mjs} +2 -2
  94. package/dist/{chunk-LE4CYW7S.mjs → chunk-FWRYUIJK.mjs} +3 -3
  95. package/dist/chunk-GDUKRUHE.mjs +29 -0
  96. package/dist/chunk-GDUKRUHE.mjs.map +1 -0
  97. package/dist/{chunk-PJRLHTGC.mjs → chunk-HPRLNT6R.mjs} +3 -3
  98. package/dist/{chunk-DOZJB6IJ.mjs → chunk-KY7JMIIS.mjs} +394 -346
  99. package/dist/chunk-KY7JMIIS.mjs.map +1 -0
  100. package/dist/{chunk-P3YZ7F22.mjs → chunk-LL7XR2H5.mjs} +34 -3
  101. package/dist/chunk-LL7XR2H5.mjs.map +1 -0
  102. package/dist/{chunk-EJIGERYM.mjs → chunk-M3MIGSH3.mjs} +2 -2
  103. package/dist/{chunk-NZAH3SGT.mjs → chunk-MVNQY2D4.mjs} +9 -4
  104. package/dist/chunk-MVNQY2D4.mjs.map +1 -0
  105. package/dist/{chunk-TGN55GKE.mjs → chunk-SC3BSCTN.mjs} +2 -2
  106. package/dist/{chunk-QQASX4LJ.mjs → chunk-TXWDUJOY.mjs} +2 -2
  107. package/dist/{chunk-EGAB6NFQ.mjs → chunk-UWJQ6UKG.mjs} +2 -2
  108. package/dist/chunk-XO2BFPTB.mjs +50 -0
  109. package/dist/chunk-XO2BFPTB.mjs.map +1 -0
  110. package/dist/{chunk-7TFV6UKF.mjs → chunk-XXKPXNQD.mjs} +1 -2
  111. package/dist/chunk-XXKPXNQD.mjs.map +1 -0
  112. package/dist/{chunk-IFNIPVTZ.mjs → chunk-Z337NBBW.mjs} +5 -49
  113. package/dist/chunk-Z337NBBW.mjs.map +1 -0
  114. package/dist/{chunk-J3LTASDE.mjs → chunk-ZHV3MQ4F.mjs} +4 -4
  115. package/dist/contexts/BeraFlags/BeraFlags.d.ts +1 -1
  116. package/dist/contexts/BeraFlags/BeraFlags.d.ts.map +1 -1
  117. package/dist/contexts/BeraFlags/defaultFlags.d.ts +2 -2
  118. package/dist/contexts/BeraFlags/defaultFlags.d.ts.map +1 -1
  119. package/dist/contexts/BexStatusProvider.d.ts +1 -1
  120. package/dist/contexts/BexStatusProvider.d.ts.map +1 -1
  121. package/dist/contexts/TokensProvider.d.ts +1 -1
  122. package/dist/contexts/TokensProvider.d.ts.map +1 -1
  123. package/dist/contexts/exports.mjs +9 -9
  124. package/dist/enum/contracts.d.ts +3 -0
  125. package/dist/enum/contracts.d.ts.map +1 -1
  126. package/dist/enum/exports.mjs +6 -4
  127. package/dist/enum/exports.mjs.map +1 -1
  128. package/dist/enum/txnEnum.d.ts +1 -1
  129. package/dist/enum/txnEnum.d.ts.map +1 -1
  130. package/dist/errors/RequestError.d.ts +19 -0
  131. package/dist/errors/RequestError.d.ts.map +1 -1
  132. package/dist/errors/errorMap.d.ts +4 -3
  133. package/dist/errors/errorMap.d.ts.map +1 -1
  134. package/dist/errors/exports.mjs +5 -5
  135. package/dist/errors/getErrorMessage.unit.test.d.ts +2 -0
  136. package/dist/errors/getErrorMessage.unit.test.d.ts.map +1 -0
  137. package/dist/generated/beep.d.ts +1597 -0
  138. package/dist/generated/beep.d.ts.map +1 -0
  139. package/dist/generated/enso.d.ts +4957 -0
  140. package/dist/generated/enso.d.ts.map +1 -0
  141. package/dist/generated/layerzero.d.ts +2057 -0
  142. package/dist/generated/layerzero.d.ts.map +1 -0
  143. package/dist/hooks/dex/useAggregatorsQuotes.d.ts.map +1 -1
  144. package/dist/hooks/dex/useAllUserPools.d.ts.map +1 -1
  145. package/dist/hooks/dex/useCrossChainNativeFee.d.ts +32 -0
  146. package/dist/hooks/dex/useCrossChainNativeFee.d.ts.map +1 -0
  147. package/dist/hooks/dex/useCrossChainNativeFee.unit.test.d.ts +2 -0
  148. package/dist/hooks/dex/useCrossChainNativeFee.unit.test.d.ts.map +1 -0
  149. package/dist/hooks/dex/useOnChainPoolData.d.ts.map +1 -1
  150. package/dist/hooks/dex/usePools.d.ts.map +1 -1
  151. package/dist/hooks/dex/useSingleAggregatorQuote.d.ts.map +1 -1
  152. package/dist/hooks/dex/useSingleAggregatorQuote.unit.test.d.ts +2 -0
  153. package/dist/hooks/dex/useSingleAggregatorQuote.unit.test.d.ts.map +1 -0
  154. package/dist/hooks/enso/useBendZapSupply.d.ts +2 -2
  155. package/dist/hooks/enso/useBendZapSupply.d.ts.map +1 -1
  156. package/dist/hooks/enso/useBendZapSupply.unit.test.d.ts +2 -0
  157. package/dist/hooks/enso/useBendZapSupply.unit.test.d.ts.map +1 -0
  158. package/dist/hooks/enso/useEnsoUserTokensWithBalances.d.ts.map +1 -1
  159. package/dist/hooks/enso/useEnsoUserTokensWithBalances.unit.test.d.ts +2 -0
  160. package/dist/hooks/enso/useEnsoUserTokensWithBalances.unit.test.d.ts.map +1 -0
  161. package/dist/hooks/enso/useZapStakeBera.d.ts.map +1 -1
  162. package/dist/hooks/enso/useZapStakeBera.unit.test.d.ts +2 -0
  163. package/dist/hooks/enso/useZapStakeBera.unit.test.d.ts.map +1 -0
  164. package/dist/hooks/exports.d.ts +2 -5
  165. package/dist/hooks/exports.d.ts.map +1 -1
  166. package/dist/hooks/exports.mjs +615 -911
  167. package/dist/hooks/exports.mjs.map +1 -1
  168. package/dist/hooks/governance/exports.mjs +4 -4
  169. package/dist/hooks/honey/useHoneyChartData.d.ts +4 -4
  170. package/dist/hooks/honey/useHoneyChartData.d.ts.map +1 -1
  171. package/dist/hooks/pol/useAutoclaimedIncentives.d.ts.map +1 -1
  172. package/dist/hooks/pol/useAutoclaimedIncentivesTxHash.d.ts.map +1 -1
  173. package/dist/hooks/pol/useRewardTokenToBeraRate.d.ts.map +1 -1
  174. package/dist/hooks/pol/useRewardVaultBalanceFromStakingToken.d.ts.map +1 -1
  175. package/dist/hooks/pol/useRewardVaults.d.ts.map +1 -1
  176. package/dist/hooks/pol/useStakedAPY.d.ts +11 -0
  177. package/dist/hooks/pol/useStakedAPY.d.ts.map +1 -0
  178. package/dist/hooks/pol/useStakedData.d.ts +4 -2
  179. package/dist/hooks/pol/useStakedData.d.ts.map +1 -1
  180. package/dist/hooks/pol/useStakedSnapshots.d.ts +1 -1
  181. package/dist/hooks/pol/useStakedSnapshots.d.ts.map +1 -1
  182. package/dist/hooks/pol/useStakingVaultsMetadata.d.ts +0 -1
  183. package/dist/hooks/pol/useStakingVaultsMetadata.d.ts.map +1 -1
  184. package/dist/hooks/tokens/useMultipleTokenInformation.d.ts +30 -0
  185. package/dist/hooks/tokens/useMultipleTokenInformation.d.ts.map +1 -1
  186. package/dist/hooks/tokens/useMultipleTokenInformation.unit.test.d.ts +2 -0
  187. package/dist/hooks/tokens/useMultipleTokenInformation.unit.test.d.ts.map +1 -0
  188. package/dist/hooks/tokens/usePollBalance.d.ts.map +1 -1
  189. package/dist/hooks/validators/useUserActiveValidators.d.ts +5 -0
  190. package/dist/hooks/validators/useUserActiveValidators.d.ts.map +1 -1
  191. package/dist/hooks/validators/useValidator.d.ts +0 -1
  192. package/dist/hooks/validators/useValidator.d.ts.map +1 -1
  193. package/dist/hooks/validators/useValidatorIncentiveDistribution.d.ts +4 -5
  194. package/dist/hooks/validators/useValidatorIncentiveDistribution.d.ts.map +1 -1
  195. package/dist/hooks/validators/useValidatorRewardAllocation.d.ts +1 -0
  196. package/dist/hooks/validators/useValidatorRewardAllocation.d.ts.map +1 -1
  197. package/dist/types/beep/exports.d.ts +2 -0
  198. package/dist/types/beep/exports.d.ts.map +1 -0
  199. package/dist/types/beep/exports.mjs +1 -0
  200. package/dist/types/beep/exports.mjs.map +1 -0
  201. package/dist/types/bribeBoost.d.ts +0 -49
  202. package/dist/types/dex.d.ts +17 -0
  203. package/dist/types/enso.d.ts +1 -27
  204. package/dist/types/global.d.ts +7 -0
  205. package/dist/types/pol.d.ts +3 -48
  206. package/dist/utils/crossChainBridge.d.ts +74 -0
  207. package/dist/utils/crossChainBridge.d.ts.map +1 -0
  208. package/dist/utils/crossChainBridge.unit.test.d.ts +2 -0
  209. package/dist/utils/crossChainBridge.unit.test.d.ts.map +1 -0
  210. package/dist/utils/exports.d.ts +1 -1
  211. package/dist/utils/exports.d.ts.map +1 -1
  212. package/dist/utils/exports.mjs +142 -72
  213. package/dist/utils/exports.mjs.map +1 -1
  214. package/dist/utils/getTestClient.d.ts +5 -3
  215. package/dist/utils/getTestClient.d.ts.map +1 -1
  216. package/dist/utils/parseWhiskToken.d.ts.map +1 -1
  217. package/package.json +14 -10
  218. package/src/actions/clients/BeraApolloClient.ts +4 -2
  219. package/src/actions/clients/clientName.ts +17 -0
  220. package/src/actions/clients/clientName.unit.test.ts +39 -0
  221. package/src/actions/clients/exports.ts +2 -0
  222. package/src/actions/clients/fetchBeep.ts +6 -4
  223. package/src/actions/clients/fetchEnso.ts +47 -0
  224. package/src/actions/clients/fetchLayerzero.ts +33 -0
  225. package/src/actions/clients/fetchOpenApi.ts +9 -2
  226. package/src/actions/clients/fetchOpenApi.unit.test.ts +27 -12
  227. package/src/actions/clients/getApolloClient.ts +3 -11
  228. package/src/actions/dex/__tests__/aggregators.unit.test.ts +231 -2
  229. package/src/actions/dex/aggregators/base.ts +75 -17
  230. package/src/actions/dex/aggregators/bex.ts +41 -1
  231. package/src/actions/dex/aggregators/bgt.ts +11 -6
  232. package/src/actions/dex/aggregators/enso/enso.ts +1 -0
  233. package/src/actions/dex/aggregators/enso/ensoErc4626.ts +27 -9
  234. package/src/actions/dex/aggregators/erc4626.ts +19 -5
  235. package/src/actions/dex/aggregators/fly.ts +1 -0
  236. package/src/actions/dex/aggregators/haiku.ts +33 -2
  237. package/src/actions/dex/aggregators/honey.ts +17 -6
  238. package/src/actions/dex/aggregators/kyberswap.ts +1 -0
  239. package/src/actions/dex/aggregators/oogabooga.ts +1 -0
  240. package/src/actions/dex/aggregators/openOcean.ts +1 -0
  241. package/src/actions/dex/aggregators/wbera.ts +17 -11
  242. package/src/actions/enso/getBendMultiplyBundle.ts +1 -1
  243. package/src/actions/enso/getEnsoUserTokensWithBalances.ts +4 -8
  244. package/src/actions/enso/util.ts +0 -59
  245. package/src/actions/exports.ts +3 -5
  246. package/src/actions/honey/getChartData.ts +2 -3
  247. package/src/actions/honey/getHoney24hVolume.ts +4 -13
  248. package/src/actions/honey/getHoneyCollaterals.ts +1 -1
  249. package/src/actions/honey/getHoneyTxns.ts +2 -3
  250. package/src/actions/pol/getBGTGlobalInfo.ts +0 -2
  251. package/src/actions/pol/getBeraTokenTotalSupply.ts +3 -33
  252. package/src/actions/pol/getEarnedStakedBeraVault.ts +1 -1
  253. package/src/actions/pol/getLSTStakeConfig.ts +0 -6
  254. package/src/actions/pol/getRewardVaults.ts +0 -1
  255. package/src/actions/pol/getSWBeraVaultMetadata.ts +2 -106
  256. package/src/actions/pol/getStakedBeraAPY.ts +44 -0
  257. package/src/actions/pol/getStakedBeraSnapshots.ts +17 -34
  258. package/src/actions/pol/getStakingDailyAssets.ts +1 -1
  259. package/src/actions/server/getDailyValidatorBlockStats.ts +1 -2
  260. package/src/actions/validators/getActiveBoostAndCommissionChangeDelay.ts +1 -1
  261. package/src/actions/validators/getUserActiveValidators.ts +116 -54
  262. package/src/actions/validators/getValidatorIncentiveDistribution.ts +1 -2
  263. package/src/actions/validators/getValidatorRewardAllocation.ts +12 -1
  264. package/src/contexts/BeraFlags/BeraFlags.tsx +1 -4
  265. package/src/contexts/BeraFlags/defaultFlags.ts +1 -3
  266. package/src/contexts/BexStatusProvider.tsx +1 -1
  267. package/src/contexts/TokensProvider.tsx +1 -4
  268. package/src/enum/contracts.ts +3 -0
  269. package/src/enum/txnEnum.ts +1 -1
  270. package/src/errors/BeraError.unit.test.ts +23 -0
  271. package/src/errors/RequestError.ts +46 -9
  272. package/src/errors/RequestError.unit.test.ts +54 -0
  273. package/src/errors/errorMap.ts +8 -3
  274. package/src/errors/getErrorMessage.unit.test.ts +32 -0
  275. package/src/generated/beep.ts +1605 -0
  276. package/src/generated/enso.ts +4965 -0
  277. package/src/generated/layerzero.ts +2065 -0
  278. package/src/hooks/dex/useAggregatorsQuotes.ts +7 -1
  279. package/src/hooks/dex/useCrossChainNativeFee.ts +83 -0
  280. package/src/hooks/dex/useCrossChainNativeFee.unit.test.ts +63 -0
  281. package/src/hooks/dex/useOnChainPoolData.ts +30 -13
  282. package/src/hooks/dex/useSingleAggregatorQuote.ts +10 -5
  283. package/src/hooks/dex/useSingleAggregatorQuote.unit.test.ts +86 -0
  284. package/src/hooks/enso/useBendZapSupply.ts +10 -38
  285. package/src/hooks/enso/useBendZapSupply.unit.test.ts +98 -0
  286. package/src/hooks/enso/useEnsoUserTokensWithBalances.ts +13 -3
  287. package/src/hooks/enso/useEnsoUserTokensWithBalances.unit.test.ts +69 -0
  288. package/src/hooks/enso/useZapStakeBera.ts +8 -1
  289. package/src/hooks/enso/useZapStakeBera.unit.test.ts +97 -0
  290. package/src/hooks/exports.ts +2 -5
  291. package/src/hooks/pol/useAutoclaimedIncentives.ts +6 -3
  292. package/src/hooks/pol/useAutoclaimedIncentivesTxHash.ts +5 -2
  293. package/src/hooks/pol/useRewardTokenToBeraRate.ts +5 -4
  294. package/src/hooks/pol/useRewardVaultBalanceFromStakingToken.ts +0 -1
  295. package/src/hooks/pol/{useStakedAPR.ts → useStakedAPY.ts} +11 -9
  296. package/src/hooks/pol/useStakedData.ts +15 -14
  297. package/src/hooks/pol/useStakedSnapshots.ts +1 -1
  298. package/src/hooks/pol/useStakingVaultsMetadata.ts +3 -8
  299. package/src/hooks/tokens/useMultipleTokenInformation.ts +64 -21
  300. package/src/hooks/tokens/useMultipleTokenInformation.unit.test.ts +91 -0
  301. package/src/hooks/tokens/usePollBalance.ts +4 -2
  302. package/src/hooks/validators/useUserActiveValidators.ts +54 -9
  303. package/src/hooks/validators/useValidatorIncentiveDistribution.ts +4 -5
  304. package/src/types/beep/exports.ts +4 -0
  305. package/src/types/bribeBoost.d.ts +0 -49
  306. package/src/types/dex.d.ts +17 -0
  307. package/src/types/enso.d.ts +1 -27
  308. package/src/types/global.d.ts +7 -0
  309. package/src/types/pol.d.ts +3 -48
  310. package/src/utils/crossChainBridge.ts +290 -0
  311. package/src/utils/crossChainBridge.unit.test.ts +177 -0
  312. package/src/utils/exports.ts +1 -1
  313. package/dist/BeraError-7-A5JYy_.d.ts +0 -123
  314. package/dist/BexStatusProvider-DRymVlQf.d.ts +0 -70
  315. package/dist/HoneyConfigProvider-COOuDNra.d.ts +0 -390
  316. package/dist/RequestError-DkUbo3ro.d.ts +0 -145
  317. package/dist/actions/dex/b-sdk.d.ts +0 -3
  318. package/dist/actions/enso/getEnsoSwapBundle.d.ts +0 -3
  319. package/dist/actions/enso/getEnsoSwapBundle.d.ts.map +0 -1
  320. package/dist/actions/pol/getBgtIncentiveDistributorPaused.d.ts +0 -10
  321. package/dist/actions/pol/getBgtIncentiveDistributorPaused.d.ts.map +0 -1
  322. package/dist/actions/pol/getRewardProofsByValidator.d.ts +0 -9
  323. package/dist/actions/pol/getRewardProofsByValidator.d.ts.map +0 -1
  324. package/dist/actions/pol/getStakedBeraAPR.d.ts +0 -12
  325. package/dist/actions/pol/getStakedBeraAPR.d.ts.map +0 -1
  326. package/dist/actions/pol/getUserClaimableIncentives.d.ts +0 -9
  327. package/dist/actions/pol/getUserClaimableIncentives.d.ts.map +0 -1
  328. package/dist/actions/validators/getValidatorAnalytics.d.ts +0 -12
  329. package/dist/actions/validators/getValidatorAnalytics.d.ts.map +0 -1
  330. package/dist/chunk-7TFV6UKF.mjs.map +0 -1
  331. package/dist/chunk-BSOWLS3W.mjs +0 -40
  332. package/dist/chunk-BSOWLS3W.mjs.map +0 -1
  333. package/dist/chunk-DOZJB6IJ.mjs.map +0 -1
  334. package/dist/chunk-IFNIPVTZ.mjs.map +0 -1
  335. package/dist/chunk-NZAH3SGT.mjs.map +0 -1
  336. package/dist/chunk-P3YZ7F22.mjs.map +0 -1
  337. package/dist/chunk-PHYZRH4I.mjs.map +0 -1
  338. package/dist/chunk-UA3Z47LT.mjs.map +0 -1
  339. package/dist/chunk-ZWTGVIPJ.mjs.map +0 -1
  340. package/dist/contexts/block-time-provider.d.ts +0 -10
  341. package/dist/defaultFlags-D6KfkTZx.d.ts +0 -10
  342. package/dist/dex-C_BB0b0O.d.ts +0 -37
  343. package/dist/getApolloClient-MWm_iq4u.d.ts +0 -39
  344. package/dist/getProposalVotes-DAUrdX2n.d.ts +0 -12
  345. package/dist/getValidatorQueuedOperatorAddress-N2I7wHd6.d.ts +0 -511
  346. package/dist/global.d-CR3zicga.d.ts +0 -231
  347. package/dist/global.d-CiZJ2eHz.d.ts +0 -231
  348. package/dist/honey-CYm0RWf4.d.ts +0 -14
  349. package/dist/hooks/enso/useEnsoSwapBundle.d.ts +0 -26
  350. package/dist/hooks/enso/useEnsoSwapBundle.d.ts.map +0 -1
  351. package/dist/hooks/pol/useBgtIncentiveDistributorPaused.d.ts +0 -8
  352. package/dist/hooks/pol/useBgtIncentiveDistributorPaused.d.ts.map +0 -1
  353. package/dist/hooks/pol/useStakedAPR.d.ts +0 -11
  354. package/dist/hooks/pol/useStakedAPR.d.ts.map +0 -1
  355. package/dist/hooks/validators/useUserClaimableIncentives.d.ts +0 -8
  356. package/dist/hooks/validators/useUserClaimableIncentives.d.ts.map +0 -1
  357. package/dist/hooks/validators/useValidatorAnalytics.d.ts +0 -11
  358. package/dist/hooks/validators/useValidatorAnalytics.d.ts.map +0 -1
  359. package/dist/pol.d-CeRgXBL8.d.ts +0 -167
  360. package/dist/txnEnum-ByI5dtDi.d.ts +0 -106
  361. package/dist/types/bribe-boost.d.ts +0 -69
  362. package/dist/useHoneySwapState-CXVWAThr.d.ts +0 -32
  363. package/dist/useHoneySwapState-twi7NTaO.d.ts +0 -32
  364. package/dist/utils/formatIncentivesTokenMap.d.ts +0 -3
  365. package/dist/utils/formatIncentivesTokenMap.d.ts.map +0 -1
  366. package/dist/utils/layerZeroScan.d.ts +0 -39
  367. package/dist/utils/layerZeroScan.d.ts.map +0 -1
  368. package/src/actions/enso/getEnsoSwapBundle.ts +0 -72
  369. package/src/actions/pol/getBgtIncentiveDistributorPaused.ts +0 -28
  370. package/src/actions/pol/getRewardProofsByValidator.ts +0 -49
  371. package/src/actions/pol/getStakedBeraAPR.ts +0 -56
  372. package/src/actions/pol/getUserClaimableIncentives.ts +0 -40
  373. package/src/actions/validators/getValidatorAnalytics.ts +0 -37
  374. package/src/hooks/enso/useEnsoSwapBundle.ts +0 -121
  375. package/src/hooks/pol/useBgtIncentiveDistributorPaused.ts +0 -34
  376. package/src/hooks/validators/useUserClaimableIncentives.ts +0 -148
  377. package/src/hooks/validators/useValidatorAnalytics.ts +0 -37
  378. package/src/utils/formatIncentivesTokenMap.ts +0 -19
  379. package/src/utils/layerZeroScan.ts +0 -124
  380. /package/dist/{chunk-AEN6IJFU.mjs.map → chunk-7KN7TDUC.mjs.map} +0 -0
  381. /package/dist/{chunk-LE4CYW7S.mjs.map → chunk-FWRYUIJK.mjs.map} +0 -0
  382. /package/dist/{chunk-PJRLHTGC.mjs.map → chunk-HPRLNT6R.mjs.map} +0 -0
  383. /package/dist/{chunk-EJIGERYM.mjs.map → chunk-M3MIGSH3.mjs.map} +0 -0
  384. /package/dist/{chunk-TGN55GKE.mjs.map → chunk-SC3BSCTN.mjs.map} +0 -0
  385. /package/dist/{chunk-QQASX4LJ.mjs.map → chunk-TXWDUJOY.mjs.map} +0 -0
  386. /package/dist/{chunk-EGAB6NFQ.mjs.map → chunk-UWJQ6UKG.mjs.map} +0 -0
  387. /package/dist/{chunk-J3LTASDE.mjs.map → chunk-ZHV3MQ4F.mjs.map} +0 -0
@@ -1,511 +0,0 @@
1
- import { Address, PublicClient } from 'viem';
2
- import { BeraConfig, ChainId } from '@berachain/config/internal';
3
- import { I as IAggregatorArgs, g as IRawAggregatorQuote, b as Token, d as HoneyConfigContextReturn, B as BalanceToken, P as PythLatestUpdates } from './HoneyConfigProvider-COOuDNra.js';
4
- import { A as Aggregators } from './dex-C_BB0b0O.js';
5
- import { GlobalDataQuery, ApiVaultFragment, GetVaultsQueryVariables, GqlChain, GetVaultHistoryQueryVariables, GetVaultHistoryQuery, ApiValidatorInListFragment } from '@berachain/graphql/pol/api';
6
- import { P as ProtocolMetadata } from './pol.d-CeRgXBL8.js';
7
-
8
- interface GetConvertToAssetsProps {
9
- sharesAmount: bigint;
10
- vaultAddress: Address;
11
- publicClient: PublicClient;
12
- }
13
- declare function getConvertToAssets({ sharesAmount, vaultAddress, publicClient, }: GetConvertToAssetsProps): Promise<{
14
- raw: bigint;
15
- formatted: string;
16
- }>;
17
-
18
- declare abstract class BaseAggregator {
19
- abstract name: Aggregators;
20
- /**
21
- * Supported chains for the aggregator.
22
- * If null, the aggregator is supported on all chains.
23
- */
24
- abstract supportedChains: number[] | null;
25
- static PATH_NOT_FOUND_REASON: "NO_SWAP_PATHS";
26
- needsAccountForQuote: boolean;
27
- notFoundMessages: string[];
28
- config: BeraConfig;
29
- chainId: ChainId;
30
- constructor(args?: BeraJS.BaseFunctionArgs);
31
- /**
32
- * Identifies the url of the last sent request. Might not have all query params.
33
- * Mainly used for error reporting.
34
- */
35
- url: string;
36
- abstract readonly type: "rest" | "graphql" | "rpc";
37
- abstract getQuote(args: IAggregatorArgs): Promise<IRawAggregatorQuote | undefined> | Promise<IRawAggregatorQuote | undefined>;
38
- /**
39
- * return wbera for native tokens to accomodate the aggregator's router logic
40
- */
41
- protected parseAddresses(tokenIn: string, tokenOut: string): {
42
- tokenInAddress: Address;
43
- tokenOutAddress: Address;
44
- isTokenInNative: boolean;
45
- isTokenOutNative: boolean;
46
- };
47
- /**
48
- * Calculate input amount after fees.
49
- *
50
- * @returns Amount in wad format
51
- */
52
- protected getAmountAfterFees(amount: string, aggregatorsFeeBps?: number): string;
53
- /**
54
- * Formats input data for aggregator swaps
55
- */
56
- protected getInputData({ tokenIn, amountIn, isNative, isPermit2Approval, permit2SpenderAddress, }: {
57
- tokenIn: Address;
58
- amountIn: string;
59
- isNative: boolean;
60
- isPermit2Approval?: boolean;
61
- permit2SpenderAddress?: Address | null;
62
- }): {
63
- tokenIn: `0x${string}`;
64
- amountIn: bigint;
65
- isNative: boolean;
66
- isPermit2Approval: boolean;
67
- permit2SpenderAddress: `0x${string}`;
68
- };
69
- /**
70
- * Calculate min amount out
71
- */
72
- protected getMinAmountOut(amountOut: string, slippage: number): bigint;
73
- protected parseAllowanceRequirements({ tokenIn, rawAmount, spender, }: {
74
- tokenIn: Token;
75
- rawAmount: string;
76
- spender: Address;
77
- }): {
78
- token: Token;
79
- amount: {
80
- raw: string;
81
- formatted: string;
82
- };
83
- spender: `0x${string}`;
84
- }[];
85
- /**
86
- * Check if chain is supported
87
- */
88
- checkChainSupport({ tokenIn, tokenOut, }: {
89
- tokenIn: Token;
90
- tokenOut: Token;
91
- honeyNativeState?: Pick<HoneyConfigContextReturn, "collateralList">;
92
- underlyingToken?: Token | null;
93
- }): boolean;
94
- assertChainSupport({ tokenIn, tokenOut, underlyingToken, }: {
95
- tokenIn: Token;
96
- tokenOut: Token;
97
- underlyingToken?: Token | null;
98
- }): void;
99
- protected fetch(url: string | URL, options?: RequestInit): Promise<Response>;
100
- }
101
-
102
- interface GetVaultsBalancesArgs extends BeraJS.BaseFunctionArgs {
103
- client: PublicClient;
104
- collateralList: Token[];
105
- honeyFactoryAddress?: Address;
106
- }
107
- interface GetHoneyVaultsBalanceResponse extends BalanceToken {
108
- vault: Address;
109
- }
110
- declare function getHoneyVaultsBalance({ client, collateralList, honeyFactoryAddress, ...args }: GetVaultsBalancesArgs): Promise<GetHoneyVaultsBalanceResponse[]>;
111
-
112
- interface IsBadCollateralArgs extends BeraJS.BaseFunctionArgs {
113
- client: PublicClient;
114
- collateral: Token;
115
- latestPrices: PythLatestUpdates | undefined;
116
- isPythWrapperEnabled: boolean;
117
- }
118
- interface IsBadCollateralResponse {
119
- isBlacklisted: boolean;
120
- isDepegged: boolean;
121
- }
122
- /**
123
- * Checks if a given collateral asset is considered bad, either by being blacklisted or depegged.
124
- *
125
- * @param {Object} args - The arguments object.
126
- * @param {PublicClient} args.client - The client used to interact with the blockchain.
127
- * @param {Token} args.collateral - The collateral asset to check.
128
- *
129
- * @returns {Promise<IsBadCollateralResponse | undefined>} An object indicating if the collateral is blacklisted or depegged.
130
- */
131
- declare function isBadCollateralAsset({ client, collateral, latestPrices, isPythWrapperEnabled, ...args }: IsBadCollateralArgs): Promise<IsBadCollateralResponse | undefined>;
132
-
133
- declare enum RewardVaultDistributionMode {
134
- Duration = "duration",
135
- TargetRate = "targetRate",
136
- TargetApr = "targetApr"
137
- }
138
- interface GetRewardVaultRewardsReturn {
139
- rewardsDuration: number;
140
- manager: Address;
141
- /**
142
- * The amount of BGT that will be distributed per second
143
- */
144
- rewardRate: string;
145
- /**
146
- * The timestamp when rewards will be depleted
147
- */
148
- periodFinish: number;
149
- /**
150
- * The amount of BGT that will be distributed from now until the periodFinish timestamp
151
- */
152
- availableRewards: string;
153
- /**
154
- * The amount of BGT that will be distributed per second.
155
- *
156
- * If this is 0, the duration mode is active.
157
- */
158
- targetRewardsPerSecond: string;
159
- /**
160
- * The minimum reward duration for the target rate
161
- */
162
- minRewardDurationForTargetRate: number;
163
- /**
164
- * The current mode of the vault
165
- */
166
- mode: RewardVaultDistributionMode.Duration | RewardVaultDistributionMode.TargetRate;
167
- }
168
- declare function getRewardVaultRewards(address: Address, publicClient: PublicClient): Promise<GetRewardVaultRewardsReturn>;
169
-
170
- type GetBgtAprSimulationArgs = {
171
- /**
172
- * Staked TVL of the vault in USD.
173
- *
174
- * Null if not available
175
- */
176
- tvl: number | null;
177
- /**
178
- * Price of BGT in USD
179
- */
180
- bgtPrice: number;
181
- /**
182
- * Undistributed BGT rewards
183
- */
184
- availableRewards: number;
185
- /**
186
- * Finish period of the reward distribution in seconds
187
- */
188
- periodFinish: number;
189
- /**
190
- * Current duration of the reward distribution in seconds. This will be used if the reward rate is 0.
191
- *
192
- */
193
- currentDuration: number;
194
- /**
195
- * Maximum reward duration in seconds
196
- */
197
- MAX_REWARD_DURATION: number;
198
- /**
199
- * Minimum reward duration in seconds
200
- */
201
- MIN_REWARD_DURATION: number;
202
- } & ({
203
- /**
204
- *
205
- */
206
- mode: RewardVaultDistributionMode.TargetApr;
207
- apr: number;
208
- /**
209
- * Minimum reward duration for the target rate
210
- */
211
- minRewardDurationForTargetRate: number;
212
- } | {
213
- /**
214
- *
215
- */
216
- mode: RewardVaultDistributionMode.TargetRate;
217
- rewardRate: number;
218
- /**
219
- * Minimum reward duration for the target rate
220
- */
221
- minRewardDurationForTargetRate: number;
222
- } | {
223
- /**
224
- *
225
- */
226
- mode: RewardVaultDistributionMode.Duration;
227
- /**
228
- * Duration of the reward distribution in seconds
229
- */
230
- duration: number;
231
- rewardRate?: never;
232
- /**
233
- * Must be between MIN_REWARD_DURATION and MAX_REWARD_DURATION
234
- */
235
- minRewardDurationForTargetRate?: never;
236
- });
237
- type GetBgtAprSimulationResult = {
238
- apr: number | null;
239
- duration: number;
240
- rewardRate: number;
241
- periodFinish: number;
242
- /**
243
- * It's the input target rate for the target rate mode.
244
- *
245
- * If input was target apr, it will be the calculated reward rate.
246
- *
247
- * If input was duration, it will be null.
248
- */
249
- targetRate: string | null;
250
- /**
251
- * If the mode is changed, this will be the new mode. Null otherwise.
252
- */
253
- mode: RewardVaultDistributionMode | null;
254
- };
255
- declare function getBgtAprSimulation({ availableRewards, periodFinish, tvl, bgtPrice, MIN_REWARD_DURATION, MAX_REWARD_DURATION, ...args }: GetBgtAprSimulationArgs): GetBgtAprSimulationResult;
256
-
257
- type ReturnedFromQuery = GlobalDataQuery["polGetGlobalInfo"] & {
258
- top3EmittingValidators: GlobalDataQuery["top3EmittingValidators"]["validators"];
259
- allValidatorsCount: number;
260
- };
261
- interface GlobalInfo extends Partial<ReturnedFromQuery> {
262
- }
263
-
264
- interface GlobalData extends GlobalInfo {
265
- bgtTotalSupply: string | undefined;
266
- bgtTotalBoosts: string | undefined;
267
- }
268
- declare function getGlobalData(publicClient: PublicClient): Promise<GlobalData>;
269
-
270
- interface GetMarkets {
271
- marketList: ProtocolMetadata[];
272
- marketDictionary: {
273
- [key: string]: ProtocolMetadata;
274
- };
275
- }
276
- declare function getMarkets(args?: BeraJS.BaseFunctionArgs): Promise<GetMarkets>;
277
-
278
- interface RewardVaultIncentive {
279
- token: Address;
280
- manager: Address;
281
- minIncentiveRate: string;
282
- incentiveRate: string;
283
- remainingAmount: string;
284
- name?: string;
285
- symbol?: string;
286
- /**
287
- * Amount of tokens that needs approval before they can be added to the incentive.
288
- *
289
- * Anyone can just `transfer` ERC20 to the vault, but incentive manager need to send accountIncentives to turn on distribution.
290
- */
291
- pendingAmount: string;
292
- decimals: number;
293
- }
294
- declare function getRewardVaultIncentives({ address, stakingToken, publicClient, }: {
295
- address: Address;
296
- stakingToken: Address;
297
- publicClient: PublicClient;
298
- }): Promise<RewardVaultIncentive[]>;
299
-
300
- interface GetRewardVaultData {
301
- rewardVaultList: ApiVaultFragment[];
302
- pagination: {
303
- currentPage: number;
304
- totalCount: number;
305
- };
306
- }
307
- declare function getRewardVaults({ filter, publicClient, ...args }?: {
308
- filter?: GetVaultsQueryVariables;
309
- publicClient?: PublicClient | undefined;
310
- } & BeraJS.BaseFunctionArgs): Promise<GetRewardVaultData>;
311
-
312
- interface VaultMetadata {
313
- current: {
314
- exchangeRate: string;
315
- totalSupply: string;
316
- totalAssets: string;
317
- tvl: string;
318
- };
319
- previous: {
320
- exchangeRate: string;
321
- totalSupply: string;
322
- totalAssets: string;
323
- tvl: string;
324
- };
325
- totalWBeraIssued: string;
326
- lockPeriod?: number;
327
- address: Address;
328
- }
329
- /**
330
- *
331
- * @param address - The address of the vault
332
- * @param underlyingAsset - The address of the vault's underlying asset token
333
- * @throws {Error} If the vault is not found
334
- * @returns
335
- */
336
- declare function getSWBeraVaultMetadata({ address, underlyingAsset, publicClient, blockTime, }: {
337
- address: Address;
338
- underlyingAsset: Address;
339
- publicClient?: PublicClient;
340
- blockTime: number;
341
- }): Promise<VaultMetadata>;
342
-
343
- /**
344
- * Interface representing a staked BERA withdrawal request
345
- */
346
- interface StakedBeraWithdrawal {
347
- receiptTokenAddress: Address;
348
- withdrawalAmount?: bigint;
349
- timeRemaining?: string;
350
- withdrawalRequestId?: bigint;
351
- }
352
- /**
353
- * Retrieves staked BERA withdrawal information for a given account
354
- *
355
- * This function handles both V1 and V2 versions of the stake vault contract:
356
- * - V1: Uses a single withdrawal request per account
357
- * - V2: Uses ERC721 tokens to represent multiple withdrawal requests per account
358
- *
359
- * @param contractAddress - The address of the stake vault contract
360
- * @param accountAddress - The address of the account to check withdrawals for
361
- * @param publicClient - Viem public client for blockchain interactions
362
- * @param version - The version of the stake vault contract ("V1" or "V2")
363
- * @returns Promise resolving to an array of withdrawal request information
364
- */
365
- declare function getSWBeraWithdrawal({ contractAddress, accountAddress, publicClient, version, }: {
366
- contractAddress: Address;
367
- accountAddress: Address;
368
- publicClient: PublicClient;
369
- version: "V1" | "V2";
370
- }): Promise<StakedBeraWithdrawal[]>;
371
-
372
- interface UserVault {
373
- unclaimedBgt: string;
374
- formattedBalance: string;
375
- stakingTokenPrice: number | null;
376
- vault: ApiVaultFragment;
377
- }
378
- type GetUserVaultsResponse = {
379
- totalStakedValue: number;
380
- totalBgtRewards: string;
381
- vaults: UserVault[];
382
- };
383
- declare function getUserVaults({ account, publicClient, ...args }: {
384
- account: Address;
385
- publicClient: PublicClient;
386
- } & BeraJS.BaseFunctionArgs): Promise<GetUserVaultsResponse>;
387
-
388
- type GetVaultHistoryArgs = {
389
- vault: Address;
390
- chain?: GqlChain;
391
- } & Omit<GetVaultHistoryQueryVariables, "vaultId" | "chain"> & BeraJS.BaseFunctionArgs;
392
- declare function getVaultHistory({ vault, chain, ...args }: GetVaultHistoryArgs): Promise<GetVaultHistoryQuery["polGetRewardVaultSnapshots"] | undefined>;
393
-
394
- interface ValidatorRewardAllocationRaw {
395
- startBlock: bigint;
396
- weights: readonly {
397
- receiver: `0x${string}`;
398
- percentageNumerator: bigint;
399
- }[];
400
- }
401
- interface ValidatorRewardAllocation {
402
- start: {
403
- blockNumber: number;
404
- timestamp: number;
405
- };
406
- weights: readonly {
407
- receiver: `0x${string}`;
408
- /**
409
- * Weight percentage as a number between 0 and 1.
410
- */
411
- percentage: number;
412
- }[];
413
- }
414
- interface ValidatorRewardAllocationUpdate {
415
- active: ValidatorRewardAllocation["start"];
416
- set: ValidatorRewardAllocation["start"];
417
- }
418
- interface ValidatorRewardAllocationUpdateWithExpiration extends ValidatorRewardAllocationUpdate {
419
- expiresAtTs: number;
420
- }
421
- declare function formatValidatorRewardAllocation(raw: ValidatorRewardAllocationRaw, startTs: number): ValidatorRewardAllocation;
422
- declare function isSameRewardAllocation(a: ValidatorRewardAllocation, b: ValidatorRewardAllocation): boolean;
423
- declare function getValidatorRewardAllocation({ client, pubKey, ...args }: BeraJS.BaseFunctionArgs & {
424
- client: PublicClient;
425
- pubKey: Address;
426
- }): Promise<{
427
- /**
428
- * The active reward allocation for the validator.
429
- */
430
- activeRewardAllocation: ValidatorRewardAllocation;
431
- /**
432
- * The set reward allocation for the validator.
433
- *
434
- * It might differ from the active reward allocation if the validator hasn't updated
435
- * the reward allocation for more than the reward allocation inactivity block span.
436
- */
437
- setRewardAllocation: ValidatorRewardAllocation;
438
- /**
439
- * Whether the reward allocation is inactive so it falls back to the baseline reward allocation.
440
- */
441
- isBaseline: boolean;
442
- isNeverSet: boolean;
443
- }>;
444
-
445
- type UserBoostsOnValidator = {
446
- pubkey: Address;
447
- /**
448
- * The amount of boosts that can be dropped.
449
- */
450
- droppableBoostAmount: string;
451
- activeBoostAmount: string;
452
- queuedBoostAmount: string;
453
- queuedBoostStartBlock: number;
454
- queuedDropBoostAmount: string;
455
- queuedDropBoostStartBlock: number;
456
- hasPendingBoosts: boolean;
457
- hasActiveBoosts: boolean;
458
- /**
459
- * Whether the user has active boosts that can be dropped.
460
- */
461
- hasDroppableBoosts: boolean;
462
- };
463
- declare function getUserBoostsOnValidator({ account, pubkey, publicClient, ...args }: {
464
- account: Address;
465
- pubkey: Address;
466
- publicClient: PublicClient | undefined;
467
- } & BeraJS.BaseFunctionArgs): Promise<UserBoostsOnValidator>;
468
-
469
- type ValidatorWithUserBoost = ApiValidatorInListFragment & {
470
- userBoosts: UserBoostsOnValidator;
471
- };
472
- declare function getUserActiveValidators({ account, publicClient, chain, ...args }: {
473
- account: string;
474
- publicClient: PublicClient | undefined;
475
- chain?: GqlChain;
476
- } & BeraJS.BaseFunctionArgs): Promise<ValidatorWithUserBoost[] | undefined>;
477
-
478
- interface StakingPoolAmount {
479
- amount: bigint;
480
- formattedAmount: string;
481
- }
482
- interface UserStakingPoolPosition {
483
- validatorAddress: Address;
484
- earning: number;
485
- staked?: StakingPoolAmount;
486
- rewards?: StakingPoolAmount;
487
- queueData?: {
488
- stake?: StakingPoolAmount[];
489
- unstake?: (StakingPoolAmount & {
490
- timestamp: number;
491
- })[];
492
- };
493
- }
494
- declare function getUserStakingPositions(account: Address): Promise<UserStakingPoolPosition[]>;
495
-
496
- interface ValidatorQueuedCommission {
497
- blockNumberLast: number;
498
- commissionRate: number;
499
- }
500
- declare function getValidatorQueuedCommission({ client, pubKey, ...args }: BeraJS.BaseFunctionArgs & {
501
- client: PublicClient;
502
- pubKey: Address;
503
- }): Promise<ValidatorQueuedCommission | undefined | null>;
504
-
505
- type ValidatorQueuedOperatorAddress = [bigint, string];
506
- declare function getValidatorQueuedOperatorAddress({ client, pubKey, ...args }: {
507
- client: PublicClient;
508
- pubKey: Address;
509
- } & BeraJS.BaseFunctionArgs): Promise<ValidatorQueuedOperatorAddress | undefined>;
510
-
511
- export { getRewardVaultIncentives as A, BaseAggregator as B, getRewardVaultRewards as C, getRewardVaults as D, getSWBeraVaultMetadata as E, getSWBeraWithdrawal as F, type GetBgtAprSimulationArgs as G, getUserActiveValidators as H, type IsBadCollateralArgs as I, getUserBoostsOnValidator as J, getUserStakingPositions as K, getUserVaults as L, getValidatorQueuedCommission as M, getValidatorQueuedOperatorAddress as N, getValidatorRewardAllocation as O, getVaultHistory as P, isBadCollateralAsset as Q, RewardVaultDistributionMode as R, type StakedBeraWithdrawal as S, isSameRewardAllocation as T, type UserBoostsOnValidator as U, type ValidatorRewardAllocation as V, type GetBgtAprSimulationResult as a, type GetConvertToAssetsProps as b, type GetHoneyVaultsBalanceResponse as c, type GetMarkets as d, type GetRewardVaultData as e, type GetRewardVaultRewardsReturn as f, type GetUserVaultsResponse as g, type GetVaultHistoryArgs as h, type GlobalData as i, type IsBadCollateralResponse as j, type RewardVaultIncentive as k, type UserStakingPoolPosition as l, type UserVault as m, type ValidatorQueuedCommission as n, type ValidatorQueuedOperatorAddress as o, type ValidatorRewardAllocationRaw as p, type ValidatorRewardAllocationUpdate as q, type ValidatorRewardAllocationUpdateWithExpiration as r, type ValidatorWithUserBoost as s, type VaultMetadata as t, formatValidatorRewardAllocation as u, getBgtAprSimulation as v, getConvertToAssets as w, getGlobalData as x, getHoneyVaultsBalance as y, getMarkets as z };