@bouncetech/contracts 1.4.1 → 1.4.3

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.
package/LICENSE ADDED
@@ -0,0 +1,22 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Bounce Tech
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
22
+
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @bouncetech/contracts
2
2
 
3
- Smart contract addresses and ABIs for [Bounce Tech](https://bouncetech.io) - DeFi Leveraged Token Protocol built on HyperEVM.
3
+ Smart contract addresses and ABIs for [Bounce Tech](https://bounce.tech/) - DeFi Leveraged Token Protocol built on HyperEVM.
4
4
 
5
5
  ## Installation
6
6
 
@@ -18,7 +18,6 @@ pnpm add @bouncetech/contracts
18
18
 
19
19
  ```typescript
20
20
  import {
21
- ALL_ADDRESSES,
22
21
  FACTORY_ADDRESS,
23
22
  GLOBAL_STORAGE_ADDRESS,
24
23
  GLOBAL_STORAGE_HELPER_ADDRESS,
@@ -27,16 +26,15 @@ import {
27
26
  LEVERAGED_TOKEN_IMPLEMENTATION_ADDRESS,
28
27
  REFERRALS_ADDRESS,
29
28
  USDC_ADDRESS,
29
+ HYPE_BALANCE_HELPER_ADDRESS,
30
30
  } from "@bouncetech/contracts";
31
31
 
32
- // Use all addresses
33
- console.log(ALL_ADDRESSES.Factory);
34
-
35
- // Or import specific addresses
32
+ // Use specific addresses
36
33
  const factoryAddress = FACTORY_ADDRESS;
37
34
  const globalStorageAddress = GLOBAL_STORAGE_ADDRESS;
38
35
  const leveragedTokenAddress = LEVERAGED_TOKEN_IMPLEMENTATION_ADDRESS;
39
36
  const usdcAddress = USDC_ADDRESS;
37
+ const hypeBalanceHelperAddress = HYPE_BALANCE_HELPER_ADDRESS;
40
38
  ```
41
39
 
42
40
  ### Import Contract ABIs
@@ -51,6 +49,7 @@ import {
51
49
  LEVERAGED_TOKEN_HELPER_ABI,
52
50
  REFERRALS_ABI,
53
51
  USDC_ABI,
52
+ HYPE_BALANCE_HELPER_ABI,
54
53
  } from "@bouncetech/contracts";
55
54
 
56
55
  // Use with ethers.js
@@ -62,11 +61,11 @@ import { createPublicClient, http } from "viem";
62
61
  const client = createPublicClient({
63
62
  transport: http(),
64
63
  });
65
- const result = await client.readContract({
64
+ const ltExists = await client.readContract({
66
65
  address: FACTORY_ADDRESS,
67
66
  abi: FACTORY_ABI,
68
- functionName: "createLeveragedToken",
69
- args: [assetAddress, leverage],
67
+ functionName: "ltExists",
68
+ args: [ltAddress],
70
69
  });
71
70
  ```
72
71
 
@@ -82,6 +81,7 @@ The following contracts are available through this package:
82
81
  - **LeveragedTokenImplementation**
83
82
  - **Referrals**
84
83
  - **USDC**
84
+ - **HypeBalanceHelper**
85
85
 
86
86
  For the latest contract addresses, import them programmatically using the exported address constants.
87
87
 
@@ -97,6 +97,7 @@ The following ABIs are available:
97
97
  - `LEVERAGED_TOKEN_HELPER_ABI` - LeveragedTokenHelper contract ABI
98
98
  - `REFERRALS_ABI` - Referrals contract ABI
99
99
  - `USDC_ABI` - USDC (ERC20) contract ABI
100
+ - `HYPE_BALANCE_HELPER_ABI` - HypeBalanceHelper contract ABI
100
101
 
101
102
  ## Updating
102
103
 
@@ -410,6 +410,25 @@ export declare const leveragedTokenHelperAbi: readonly [{
410
410
  }];
411
411
  }];
412
412
  readonly stateMutability: "view";
413
+ }, {
414
+ readonly type: "function";
415
+ readonly name: "getTotalAssets";
416
+ readonly inputs: readonly [];
417
+ readonly outputs: readonly [{
418
+ readonly name: "";
419
+ readonly type: "tuple[]";
420
+ readonly internalType: "struct ILeveragedTokenHelper.TotalAssets[]";
421
+ readonly components: readonly [{
422
+ readonly name: "leveragedTokenAddress";
423
+ readonly type: "address";
424
+ readonly internalType: "address";
425
+ }, {
426
+ readonly name: "totalAssets";
427
+ readonly type: "uint256";
428
+ readonly internalType: "uint256";
429
+ }];
430
+ }];
431
+ readonly stateMutability: "view";
413
432
  }, {
414
433
  readonly type: "error";
415
434
  readonly name: "DivisionByZero";
@@ -532,6 +532,31 @@ exports.leveragedTokenHelperAbi = [
532
532
  ],
533
533
  "stateMutability": "view",
534
534
  },
535
+ {
536
+ "type": "function",
537
+ "name": "getTotalAssets",
538
+ "inputs": [],
539
+ "outputs": [
540
+ {
541
+ "name": "",
542
+ "type": "tuple[]",
543
+ "internalType": "struct ILeveragedTokenHelper.TotalAssets[]",
544
+ "components": [
545
+ {
546
+ "name": "leveragedTokenAddress",
547
+ "type": "address",
548
+ "internalType": "address",
549
+ },
550
+ {
551
+ "name": "totalAssets",
552
+ "type": "uint256",
553
+ "internalType": "uint256",
554
+ },
555
+ ],
556
+ },
557
+ ],
558
+ "stateMutability": "view",
559
+ },
535
560
  {
536
561
  "type": "error",
537
562
  "name": "DivisionByZero",
package/dist/index.d.ts CHANGED
@@ -3,11 +3,11 @@ export declare const FACTORY_ADDRESS = "0xeD8bCDe433EB7c4B69DB1235483bf0Edb726Fc
3
3
  export declare const GLOBAL_STORAGE_ADDRESS = "0xa07d06383c1863c8A54d427aC890643d76cc03ff";
4
4
  export declare const GLOBAL_STORAGE_HELPER_ADDRESS = "0x99836aCBD207d5BCa57E3Fe0448bD1AB0A4BDf5C";
5
5
  export declare const HYPERLIQUID_HANDLER_ADDRESS = "0x0f1365392EA9Df901dEb94d100679E7440E499bc";
6
- export declare const LEVERAGED_TOKEN_HELPER_ADDRESS = "0x4a548ad41888B023850130Bf931453Bb7d07aD23";
6
+ export declare const LEVERAGED_TOKEN_HELPER_ADDRESS = "0xb896d6D547350418e9510065389c9c0d92ca4F17";
7
7
  export declare const LEVERAGED_TOKEN_IMPLEMENTATION_ADDRESS = "0x126e039f97Dd34fa64E685Ba4b37ca97b1a03DcB";
8
8
  export declare const REFERRALS_ADDRESS = "0xfD3A6323878Fc991447CcDd4c644ab419afC6f76";
9
9
  export declare const USDC_ADDRESS = "0xb88339CB7199b77E23DB6E890353E22632Ba630f";
10
- export declare const HYPE_BALANCE_HELPER = "0x7B8CFf7E3b8Be150e735f2AF56DBB69ec44d91b3";
10
+ export declare const HYPE_BALANCE_HELPER_ADDRESS = "0x7B8CFf7E3b8Be150e735f2AF56DBB69ec44d91b3";
11
11
  export declare const FACTORY_ABI: readonly [{
12
12
  readonly type: "constructor";
13
13
  readonly inputs: readonly [{
@@ -2723,6 +2723,25 @@ export declare const LEVERAGED_TOKEN_HELPER_ABI: readonly [{
2723
2723
  }];
2724
2724
  }];
2725
2725
  readonly stateMutability: "view";
2726
+ }, {
2727
+ readonly type: "function";
2728
+ readonly name: "getTotalAssets";
2729
+ readonly inputs: readonly [];
2730
+ readonly outputs: readonly [{
2731
+ readonly name: "";
2732
+ readonly type: "tuple[]";
2733
+ readonly internalType: "struct ILeveragedTokenHelper.TotalAssets[]";
2734
+ readonly components: readonly [{
2735
+ readonly name: "leveragedTokenAddress";
2736
+ readonly type: "address";
2737
+ readonly internalType: "address";
2738
+ }, {
2739
+ readonly name: "totalAssets";
2740
+ readonly type: "uint256";
2741
+ readonly internalType: "uint256";
2742
+ }];
2743
+ }];
2744
+ readonly stateMutability: "view";
2726
2745
  }, {
2727
2746
  readonly type: "error";
2728
2747
  readonly name: "DivisionByZero";
@@ -3226,3 +3245,27 @@ export declare const USDC_ABI: readonly [{
3226
3245
  }];
3227
3246
  readonly anonymous: false;
3228
3247
  }];
3248
+ export declare const HYPE_BALANCE_HELPER_ABI: readonly [{
3249
+ readonly type: "function";
3250
+ readonly name: "getHypeBalances";
3251
+ readonly inputs: readonly [{
3252
+ readonly name: "users_";
3253
+ readonly type: "address[]";
3254
+ readonly internalType: "address[]";
3255
+ }];
3256
+ readonly outputs: readonly [{
3257
+ readonly name: "";
3258
+ readonly type: "tuple[]";
3259
+ readonly internalType: "struct IHypeBalanceHelper.UserBalance[]";
3260
+ readonly components: readonly [{
3261
+ readonly name: "user";
3262
+ readonly type: "address";
3263
+ readonly internalType: "address";
3264
+ }, {
3265
+ readonly name: "balance";
3266
+ readonly type: "uint256";
3267
+ readonly internalType: "uint256";
3268
+ }];
3269
+ }];
3270
+ readonly stateMutability: "view";
3271
+ }];
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.USDC_ABI = exports.REFERRALS_ABI = exports.LEVERAGED_TOKEN_HELPER_ABI = exports.LEVERAGED_TOKEN_ABI = exports.HYPERLIQUID_HANDLER_ABI = exports.GLOBAL_STORAGE_HELPER_ABI = exports.GLOBAL_STORAGE_ABI = exports.FACTORY_ABI = exports.HYPE_BALANCE_HELPER = exports.USDC_ADDRESS = exports.REFERRALS_ADDRESS = exports.LEVERAGED_TOKEN_IMPLEMENTATION_ADDRESS = exports.LEVERAGED_TOKEN_HELPER_ADDRESS = exports.HYPERLIQUID_HANDLER_ADDRESS = exports.GLOBAL_STORAGE_HELPER_ADDRESS = exports.GLOBAL_STORAGE_ADDRESS = exports.FACTORY_ADDRESS = void 0;
3
+ exports.HYPE_BALANCE_HELPER_ABI = exports.USDC_ABI = exports.REFERRALS_ABI = exports.LEVERAGED_TOKEN_HELPER_ABI = exports.LEVERAGED_TOKEN_ABI = exports.HYPERLIQUID_HANDLER_ABI = exports.GLOBAL_STORAGE_HELPER_ABI = exports.GLOBAL_STORAGE_ABI = exports.FACTORY_ABI = exports.HYPE_BALANCE_HELPER_ADDRESS = exports.USDC_ADDRESS = exports.REFERRALS_ADDRESS = exports.LEVERAGED_TOKEN_IMPLEMENTATION_ADDRESS = exports.LEVERAGED_TOKEN_HELPER_ADDRESS = exports.HYPERLIQUID_HANDLER_ADDRESS = exports.GLOBAL_STORAGE_HELPER_ADDRESS = exports.GLOBAL_STORAGE_ADDRESS = exports.FACTORY_ADDRESS = void 0;
4
4
  const leveraged_token_abi_1 = require("./abis/leveraged-token-abi");
5
5
  const factory_abi_1 = require("./abis/factory-abi");
6
6
  const global_storage_abi_1 = require("./abis/global-storage-abi");
@@ -9,16 +9,17 @@ const hyperliquid_handler_abi_1 = require("./abis/hyperliquid-handler-abi");
9
9
  const leveraged_token_helper_abi_1 = require("./abis/leveraged-token-helper-abi");
10
10
  const referrals_abi_1 = require("./abis/referrals-abi");
11
11
  const erc20_abi_1 = require("./abis/erc20-abi");
12
+ const hype_balance_helper_abi_1 = require("./abis/hype-balance-helper-abi");
12
13
  // Addresses
13
14
  exports.FACTORY_ADDRESS = "0xeD8bCDe433EB7c4B69DB1235483bf0Edb726Fc1B";
14
15
  exports.GLOBAL_STORAGE_ADDRESS = "0xa07d06383c1863c8A54d427aC890643d76cc03ff";
15
16
  exports.GLOBAL_STORAGE_HELPER_ADDRESS = "0x99836aCBD207d5BCa57E3Fe0448bD1AB0A4BDf5C";
16
17
  exports.HYPERLIQUID_HANDLER_ADDRESS = "0x0f1365392EA9Df901dEb94d100679E7440E499bc";
17
- exports.LEVERAGED_TOKEN_HELPER_ADDRESS = "0x4a548ad41888B023850130Bf931453Bb7d07aD23";
18
+ exports.LEVERAGED_TOKEN_HELPER_ADDRESS = "0xb896d6D547350418e9510065389c9c0d92ca4F17";
18
19
  exports.LEVERAGED_TOKEN_IMPLEMENTATION_ADDRESS = "0x126e039f97Dd34fa64E685Ba4b37ca97b1a03DcB";
19
20
  exports.REFERRALS_ADDRESS = "0xfD3A6323878Fc991447CcDd4c644ab419afC6f76";
20
21
  exports.USDC_ADDRESS = "0xb88339CB7199b77E23DB6E890353E22632Ba630f";
21
- exports.HYPE_BALANCE_HELPER = "0x7B8CFf7E3b8Be150e735f2AF56DBB69ec44d91b3";
22
+ exports.HYPE_BALANCE_HELPER_ADDRESS = "0x7B8CFf7E3b8Be150e735f2AF56DBB69ec44d91b3";
22
23
  // ABIs
23
24
  exports.FACTORY_ABI = factory_abi_1.factoryAbi;
24
25
  exports.GLOBAL_STORAGE_ABI = global_storage_abi_1.globalStorageAbi;
@@ -28,3 +29,4 @@ exports.LEVERAGED_TOKEN_ABI = leveraged_token_abi_1.leveragedTokenAbi;
28
29
  exports.LEVERAGED_TOKEN_HELPER_ABI = leveraged_token_helper_abi_1.leveragedTokenHelperAbi;
29
30
  exports.REFERRALS_ABI = referrals_abi_1.referralsAbi;
30
31
  exports.USDC_ABI = erc20_abi_1.erc20Abi;
32
+ exports.HYPE_BALANCE_HELPER_ABI = hype_balance_helper_abi_1.hypeBalanceHelperAbi;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bouncetech/contracts",
3
- "version": "1.4.1",
3
+ "version": "1.4.3",
4
4
  "description": "Smart contract addresses and ABIs for Bounce Tech - DeFi Leveraged Token Protocol on HyperEVM",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",