@interest-protocol/vortex-sdk 0.0.1-alpha.0 → 1.1.0

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 (121) hide show
  1. package/.eslingignore +1 -0
  2. package/dist/__tests__/entities/keypair.spec.d.ts +2 -0
  3. package/dist/__tests__/entities/keypair.spec.d.ts.map +1 -0
  4. package/dist/__tests__/test-utils.d.ts +25 -0
  5. package/dist/__tests__/test-utils.d.ts.map +1 -0
  6. package/dist/__tests__/types.d.ts +3 -0
  7. package/dist/__tests__/types.d.ts.map +1 -0
  8. package/dist/__tests__/vortex.test.d.ts +2 -0
  9. package/dist/__tests__/vortex.test.d.ts.map +1 -0
  10. package/dist/constants.d.ts +44 -0
  11. package/dist/constants.d.ts.map +1 -0
  12. package/dist/crypto/ff/f1field.d.ts +76 -0
  13. package/dist/crypto/ff/f1field.d.ts.map +1 -0
  14. package/dist/crypto/ff/index.d.ts +6 -0
  15. package/dist/crypto/ff/index.d.ts.map +1 -0
  16. package/dist/crypto/ff/random.d.ts +2 -0
  17. package/dist/crypto/ff/random.d.ts.map +1 -0
  18. package/dist/crypto/ff/scalar.d.ts +45 -0
  19. package/dist/crypto/ff/scalar.d.ts.map +1 -0
  20. package/dist/crypto/ff/utils.d.ts +6 -0
  21. package/dist/crypto/ff/utils.d.ts.map +1 -0
  22. package/dist/crypto/index.d.ts +6 -0
  23. package/dist/crypto/index.d.ts.map +1 -0
  24. package/dist/crypto/poseidon/index.d.ts +2 -0
  25. package/dist/crypto/poseidon/index.d.ts.map +1 -0
  26. package/dist/crypto/poseidon/poseidon-constants-opt.d.ts +7 -0
  27. package/dist/crypto/poseidon/poseidon-constants-opt.d.ts.map +1 -0
  28. package/dist/crypto/poseidon/poseidon-opt.d.ts +16 -0
  29. package/dist/crypto/poseidon/poseidon-opt.d.ts.map +1 -0
  30. package/dist/deposit.d.ts +4 -0
  31. package/dist/deposit.d.ts.map +1 -0
  32. package/dist/entities/index.d.ts +4 -0
  33. package/dist/entities/index.d.ts.map +1 -0
  34. package/dist/entities/keypair.d.ts +29 -0
  35. package/dist/entities/keypair.d.ts.map +1 -0
  36. package/dist/entities/merkle-tree.d.ts +81 -0
  37. package/dist/entities/merkle-tree.d.ts.map +1 -0
  38. package/dist/entities/utxo.d.ts +24 -0
  39. package/dist/entities/utxo.d.ts.map +1 -0
  40. package/dist/index.d.ts +6 -2
  41. package/dist/index.d.ts.map +1 -1
  42. package/dist/index.js +38280 -4459
  43. package/dist/index.js.map +1 -1
  44. package/dist/index.mjs +38244 -4453
  45. package/dist/index.mjs.map +1 -1
  46. package/dist/jest-setup.d.ts +2 -0
  47. package/dist/jest-setup.d.ts.map +1 -0
  48. package/dist/keys/index.d.ts +3 -0
  49. package/dist/keys/index.d.ts.map +1 -0
  50. package/dist/pkg/nodejs/vortex.d.ts +11 -0
  51. package/dist/pkg/nodejs/vortex.d.ts.map +1 -0
  52. package/dist/pkg/web/vortex.d.ts +44 -0
  53. package/dist/pkg/web/vortex.d.ts.map +1 -0
  54. package/dist/utils/decrypt.d.ts +12 -0
  55. package/dist/utils/decrypt.d.ts.map +1 -0
  56. package/dist/utils/env.d.ts +2 -0
  57. package/dist/utils/env.d.ts.map +1 -0
  58. package/dist/utils/events.d.ts +7 -0
  59. package/dist/utils/events.d.ts.map +1 -0
  60. package/dist/utils/ext-data.d.ts +3 -0
  61. package/dist/utils/ext-data.d.ts.map +1 -0
  62. package/dist/utils/index.d.ts +50 -0
  63. package/dist/utils/index.d.ts.map +1 -0
  64. package/dist/utils/prove.d.ts +3 -0
  65. package/dist/utils/prove.d.ts.map +1 -0
  66. package/dist/vortex.d.ts +51 -21
  67. package/dist/vortex.d.ts.map +1 -1
  68. package/dist/vortex.types.d.ts +74 -50
  69. package/dist/vortex.types.d.ts.map +1 -1
  70. package/dist/vortex_bg.wasm +0 -0
  71. package/dist/withdraw.d.ts +4 -0
  72. package/dist/withdraw.d.ts.map +1 -0
  73. package/jest.config.js +31 -0
  74. package/package.json +22 -7
  75. package/src/__tests__/entities/keypair.spec.ts +191 -0
  76. package/src/__tests__/test-utils.ts +76 -0
  77. package/src/__tests__/types.ts +3 -0
  78. package/src/__tests__/vortex.test.ts +25 -0
  79. package/src/constants.ts +104 -0
  80. package/src/crypto/ff/f1field.ts +464 -0
  81. package/src/crypto/ff/index.ts +6 -0
  82. package/src/crypto/ff/random.ts +32 -0
  83. package/src/crypto/ff/readme.md +8 -0
  84. package/src/crypto/ff/scalar.ts +264 -0
  85. package/src/crypto/ff/utils.ts +121 -0
  86. package/src/crypto/index.ts +8 -0
  87. package/src/crypto/poseidon/index.ts +1 -0
  88. package/src/crypto/poseidon/poseidon-constants-opt.ts +24806 -0
  89. package/src/crypto/poseidon/poseidon-opt.ts +184 -0
  90. package/src/deposit.ts +168 -0
  91. package/src/entities/index.ts +3 -0
  92. package/src/entities/keypair.ts +262 -0
  93. package/src/entities/merkle-tree.ts +256 -0
  94. package/src/entities/utxo.ts +52 -0
  95. package/src/index.ts +6 -2
  96. package/src/jest-setup.ts +2 -0
  97. package/src/keys/index.ts +5 -0
  98. package/src/pkg/nodejs/vortex.d.ts +36 -0
  99. package/src/pkg/nodejs/vortex.js +332 -0
  100. package/src/pkg/nodejs/vortex_bg.wasm +0 -0
  101. package/src/pkg/nodejs/vortex_bg.wasm.d.ts +12 -0
  102. package/src/pkg/web/vortex.d.ts +72 -0
  103. package/src/pkg/web/vortex.js +442 -0
  104. package/src/pkg/web/vortex_bg.wasm +0 -0
  105. package/src/pkg/web/vortex_bg.wasm.d.ts +12 -0
  106. package/src/utils/decrypt.ts +46 -0
  107. package/src/utils/env.ts +18 -0
  108. package/src/utils/events.ts +16 -0
  109. package/src/utils/ext-data.ts +43 -0
  110. package/src/utils/index.ts +152 -0
  111. package/src/utils/prove.ts +18 -0
  112. package/src/vortex.ts +235 -111
  113. package/src/vortex.types.ts +74 -54
  114. package/src/withdraw.ts +159 -0
  115. package/tsconfig.json +4 -2
  116. package/dist/admin.d.ts +0 -17
  117. package/dist/admin.d.ts.map +0 -1
  118. package/dist/utils.d.ts +0 -11
  119. package/dist/utils.d.ts.map +0 -1
  120. package/src/admin.ts +0 -124
  121. package/src/utils.ts +0 -66
@@ -0,0 +1,191 @@
1
+ import { VortexKeypair } from '../../entities/keypair';
2
+ import { BN254_FIELD_MODULUS } from '../../constants';
3
+ import { Ed25519Keypair } from '@mysten/sui/keypairs/ed25519';
4
+
5
+ describe(VortexKeypair.name, () => {
6
+ describe('generate', () => {
7
+ it('should generate a valid keypair', () => {
8
+ const keypair = VortexKeypair.generate();
9
+
10
+ expect(keypair.privateKey).toBeDefined();
11
+ expect(keypair.publicKey).toBeDefined();
12
+ expect(keypair.encryptionKey).toBeDefined();
13
+ expect(typeof keypair.publicKey).toBe('string');
14
+ });
15
+
16
+ it('should generate different keypairs each time', () => {
17
+ const keypair1 = VortexKeypair.generate();
18
+ const keypair2 = VortexKeypair.generate();
19
+
20
+ expect(keypair1.privateKey).not.toBe(keypair2.privateKey);
21
+ expect(keypair1.publicKey).not.toBe(keypair2.publicKey);
22
+ });
23
+
24
+ it('should ensure private key is within BN254 field', () => {
25
+ const keypair = VortexKeypair.generate();
26
+ expect(keypair.privateKey).toBeLessThanOrEqual(BN254_FIELD_MODULUS);
27
+ });
28
+ });
29
+
30
+ describe('fromString', () => {
31
+ it('should create keypair from string', () => {
32
+ const keypair = VortexKeypair.generate();
33
+ const keypairString = keypair.toString();
34
+ const restoredKeypair = VortexKeypair.fromString(keypairString);
35
+
36
+ expect(restoredKeypair.publicKey).toBe(keypair.publicKey);
37
+ expect(restoredKeypair.encryptionKey).toBe(keypair.encryptionKey);
38
+ });
39
+
40
+ it('should handle 0x prefix', () => {
41
+ const keypair = VortexKeypair.generate();
42
+ const withPrefix = keypair.toString();
43
+ const withoutPrefix = withPrefix.slice(2);
44
+
45
+ const keypair1 = VortexKeypair.fromString(withPrefix);
46
+ const keypair2 = VortexKeypair.fromString(withoutPrefix);
47
+
48
+ expect(keypair1.publicKey).toBe(keypair2.publicKey);
49
+ });
50
+ });
51
+
52
+ describe('sign', () => {
53
+ it('should produce consistent signatures', () => {
54
+ const keypair = VortexKeypair.generate();
55
+ const commitment = 123n;
56
+ const merklePath = 456n;
57
+
58
+ const sig1 = keypair.sign(commitment, merklePath);
59
+ const sig2 = keypair.sign(commitment, merklePath);
60
+
61
+ expect(sig1).toBe(sig2);
62
+ });
63
+
64
+ it('should produce different signatures for different inputs', () => {
65
+ const keypair = VortexKeypair.generate();
66
+
67
+ const sig1 = keypair.sign(123n, 456n);
68
+ const sig2 = keypair.sign(789n, 456n);
69
+
70
+ expect(sig1).not.toBe(sig2);
71
+ });
72
+ });
73
+
74
+ describe('encryption/decryption', () => {
75
+ it('should encrypt and decrypt UTXO data', () => {
76
+ const keypair = VortexKeypair.generate();
77
+ const utxo = {
78
+ amount: 1000n,
79
+ blinding: 999n,
80
+ index: 5n,
81
+ };
82
+
83
+ const encrypted = VortexKeypair.encryptUtxoFor(
84
+ utxo,
85
+ keypair.encryptionKey
86
+ );
87
+ const decrypted = keypair.decryptUtxo(encrypted);
88
+
89
+ expect(decrypted.amount).toBe(utxo.amount);
90
+ expect(decrypted.blinding).toBe(utxo.blinding);
91
+ expect(decrypted.index).toBe(utxo.index);
92
+ });
93
+
94
+ it('should fail to decrypt with wrong keypair', () => {
95
+ const keypair1 = VortexKeypair.generate();
96
+ const keypair2 = VortexKeypair.generate();
97
+
98
+ const utxo = {
99
+ amount: 1000n,
100
+ blinding: 999n,
101
+ index: 5n,
102
+ };
103
+
104
+ const encrypted = VortexKeypair.encryptUtxoFor(
105
+ utxo,
106
+ keypair1.encryptionKey
107
+ );
108
+
109
+ // Attempting to decrypt with wrong keypair should throw or produce garbage
110
+ expect(() => keypair2.decryptUtxo(encrypted)).toThrow();
111
+ });
112
+ });
113
+
114
+ describe('toString/address', () => {
115
+ it('should produce consistent string representation', () => {
116
+ const keypair = VortexKeypair.generate();
117
+ const str1 = keypair.toString();
118
+ const str2 = keypair.toString();
119
+
120
+ expect(str1).toBe(str2);
121
+ });
122
+
123
+ it('should start with 0x', () => {
124
+ const keypair = VortexKeypair.generate();
125
+ expect(keypair.toString()).toMatch(/^0x/);
126
+ });
127
+
128
+ it('address should match toString', () => {
129
+ const keypair = VortexKeypair.generate();
130
+ expect(keypair.address()).toBe(keypair.toString());
131
+ });
132
+ });
133
+
134
+ describe('fromSuiWallet', () => {
135
+ it('should create keypair from Sui wallet', async () => {
136
+ const suiWallet = Ed25519Keypair.generate();
137
+
138
+ const keypair = await VortexKeypair.fromSuiWallet(
139
+ suiWallet.toSuiAddress(),
140
+ async (message) => suiWallet.signPersonalMessage(message)
141
+ );
142
+
143
+ expect(keypair.publicKey).toBeDefined();
144
+ expect(keypair.encryptionKey).toBeDefined();
145
+ expect(keypair.privateKey).toBeDefined();
146
+ expect(typeof keypair.privateKey).toBe('bigint');
147
+ expect(typeof keypair.publicKey).toBe('string');
148
+ expect(typeof keypair.encryptionKey).toBe('string');
149
+ expect(keypair.privateKey).toBeLessThanOrEqual(BN254_FIELD_MODULUS);
150
+ });
151
+
152
+ it('should recreate the same keypair from the same Sui wallet', async () => {
153
+ const suiWallet = Ed25519Keypair.generate();
154
+ const keypair = await VortexKeypair.fromSuiWallet(
155
+ suiWallet.toSuiAddress(),
156
+ async (message) => suiWallet.signPersonalMessage(message)
157
+ );
158
+
159
+ const keypair2 = await VortexKeypair.fromSuiWallet(
160
+ suiWallet.toSuiAddress(),
161
+ async (message) => suiWallet.signPersonalMessage(message)
162
+ );
163
+
164
+ expect(keypair.publicKey).toBe(keypair2.publicKey);
165
+ expect(keypair.encryptionKey).toBe(keypair2.encryptionKey);
166
+ expect(keypair.privateKey).toBe(keypair2.privateKey);
167
+ expect(keypair.address()).toBe(keypair2.address());
168
+ expect(keypair.toString()).toBe(keypair2.toString());
169
+ });
170
+
171
+ it('should create a different keypair for a different Sui wallet', async () => {
172
+ const suiWallet1 = Ed25519Keypair.generate();
173
+ const suiWallet2 = Ed25519Keypair.generate();
174
+
175
+ const keypair1 = await VortexKeypair.fromSuiWallet(
176
+ suiWallet1.toSuiAddress(),
177
+ async (message) => suiWallet1.signPersonalMessage(message)
178
+ );
179
+ const keypair2 = await VortexKeypair.fromSuiWallet(
180
+ suiWallet2.toSuiAddress(),
181
+ async (message) => suiWallet2.signPersonalMessage(message)
182
+ );
183
+
184
+ expect(keypair1.publicKey).not.toBe(keypair2.publicKey);
185
+ expect(keypair1.encryptionKey).not.toBe(keypair2.encryptionKey);
186
+ expect(keypair1.privateKey).not.toBe(keypair2.privateKey);
187
+ expect(keypair1.address()).not.toBe(keypair2.address());
188
+ expect(keypair1.toString()).not.toBe(keypair2.toString());
189
+ });
190
+ });
191
+ });
@@ -0,0 +1,76 @@
1
+ import { SuiClient, getFullnodeUrl } from '@mysten/sui/client';
2
+ import { Transaction, TransactionArgument } from '@mysten/sui/transactions';
3
+
4
+ import { Vortex } from '../vortex';
5
+
6
+ export const devnetSuiClient = new SuiClient({
7
+ url: getFullnodeUrl('devnet'),
8
+ });
9
+
10
+ export const TEST_VORTEX_PACKAGE_ID =
11
+ '0xe5c3cc57317735311a9e054fa3d59c625d6e530ab9b9499409c4a7157fbfbaba';
12
+
13
+ export const TEST_VORTEX_SHARED_OBJECT_ID =
14
+ '0x9751819ded69b113eea0ca81b4fcb95be8a07b166a88858ce58057417b5713d3';
15
+
16
+ export const TEST_REGISTRY_SHARED_OBJECT_ID =
17
+ '0x86b4429f15c699d4a225474be82490f1165c1123228dcfedc6966c245b840ac2';
18
+
19
+ export const TEST_UPGRADE_CAP_ID =
20
+ '0xb76878578f39017a04a892e7250a146c13663282de80876fae7d62fb5b073f4b';
21
+
22
+ export const TEST_REGISTRY_INITIAL_SHARED_VERSION = '8';
23
+
24
+ export const TEST_VORTEX_INITIAL_SHARED_VERSION = '8';
25
+
26
+ interface ExpectDevInspectTransactionBlockArgs {
27
+ tx: Transaction;
28
+ sender: string;
29
+ expectStatus: 'success' | 'failure';
30
+ }
31
+
32
+ export const expectDevInspectTransactionBlock = async ({
33
+ tx,
34
+ sender,
35
+ expectStatus,
36
+ }: ExpectDevInspectTransactionBlockArgs) => {
37
+ const result = await devnetSuiClient.devInspectTransactionBlock({
38
+ sender,
39
+ transactionBlock: tx,
40
+ });
41
+
42
+ if (result.effects.status.status !== expectStatus) {
43
+ console.log(result);
44
+ }
45
+ expect(result.effects.status.status).toBe(expectStatus);
46
+ };
47
+
48
+ export const testVortex = new Vortex({
49
+ registry: {
50
+ objectId: TEST_REGISTRY_SHARED_OBJECT_ID,
51
+ initialSharedVersion: TEST_REGISTRY_INITIAL_SHARED_VERSION,
52
+ },
53
+ vortex: {
54
+ objectId: TEST_VORTEX_SHARED_OBJECT_ID,
55
+ initialSharedVersion: TEST_VORTEX_INITIAL_SHARED_VERSION,
56
+ },
57
+ packageId: TEST_VORTEX_PACKAGE_ID,
58
+ });
59
+
60
+ interface AssertValueArgs {
61
+ tx: Transaction;
62
+ typeArguments: string[];
63
+ args: TransactionArgument[];
64
+ }
65
+
66
+ export const assertValueMoveCall = ({
67
+ tx,
68
+ typeArguments,
69
+ args,
70
+ }: AssertValueArgs) => {
71
+ tx.moveCall({
72
+ target: `${TEST_VORTEX_PACKAGE_ID}::vortex::assert_value`,
73
+ arguments: args,
74
+ typeArguments: typeArguments,
75
+ });
76
+ };
@@ -0,0 +1,3 @@
1
+ export const STRING_TYPE_ARGUMENT = '0x1::string::String';
2
+
3
+ export const OPTION_STRING_TYPE_ARGUMENT = `0x1::option::Option<${STRING_TYPE_ARGUMENT}>`;
@@ -0,0 +1,25 @@
1
+ import { testVortex } from './test-utils';
2
+ import { MERKLE_TREE_HEIGHT, EMPTY_SUBTREE_HASHES } from '../constants';
3
+
4
+ describe('Vortex', () => {
5
+ it('should get the TVL', async () => {
6
+ const tvl = await testVortex.tvl();
7
+ expect(tvl).toBe(0n);
8
+ });
9
+
10
+ it('should get the root', async () => {
11
+ const root = await testVortex.root();
12
+ expect(root).toBe(String(EMPTY_SUBTREE_HASHES[MERKLE_TREE_HEIGHT]));
13
+ });
14
+
15
+ it('should get the next index', async () => {
16
+ const nextIndex = await testVortex.nextIndex();
17
+ expect(nextIndex).toBe('0');
18
+ });
19
+
20
+ it('should check if a nullifier is spent', async () => {
21
+ const nullifier = 12345n;
22
+ const isNullifierSpent = await testVortex.isNullifierSpent(nullifier);
23
+ expect(isNullifierSpent).toBe(false);
24
+ });
25
+ });
@@ -0,0 +1,104 @@
1
+ export const BN254_FIELD_MODULUS =
2
+ 21888242871839275222246405745257275088548364400416034343698204186575808495617n;
3
+
4
+ // ZERO_VALUE := Poseidon("vortex")
5
+ export const ZERO_VALUE =
6
+ 18688842432741139442778047327644092677418528270738216181718229581494125774932n;
7
+
8
+ export const EMPTY_COMMITMENT = ZERO_VALUE;
9
+
10
+ export enum Output {
11
+ HasCommitments,
12
+ NoCommitments,
13
+ }
14
+
15
+ export const EMPTY_SUBTREE_HASHES = [
16
+ ZERO_VALUE,
17
+ 929670100605127589096201729966801143828059989180770638007278601230757123028n,
18
+ 20059153686521406362481271315473498068253845102360114882796737328118528819600n,
19
+ 667276972495892769517195136104358636854444397700904910347259067486374491460n,
20
+ 12333205860481369973758777121486440301866097422034925170601892818077919669856n,
21
+ 13265906118204670164732063746425660672195834675096811019428798251172285860978n,
22
+ 3254533810100792365765975246297999341668420141674816325048742255119776645299n,
23
+ 18309808253444361227126414342398728022042151803316641228967342967902364963927n,
24
+ 12126650299593052178871547753567584772895820192048806970138326036720774331291n,
25
+ 9949817351285988369728267498508465715570337443235086859122087250007803517342n,
26
+ 11208526958197959509185914785003803401681281543885952782991980697855275912368n,
27
+ 59685738145310886711325295148553591612803302297715439999772116453982910402n,
28
+ 20837058910394942465479261789141487609029093821244922450759151002393360448717n,
29
+ 8209451842087447702442792222326370366485985268583914555249981462794434142285n,
30
+ 19651337661238139284113069695072175498780734789512991455990330919229086149402n,
31
+ 11527931080332651861006914960138009072130600556413592683110711451245237795573n,
32
+ 20764556403192106825184782309105498322242675071639346714780565918367449744227n,
33
+ 10818178251908058160377157228631396071771716850372988172358158281935915764080n,
34
+ 21598305620835755437985090087223184201582363356396834169567261294737143234327n,
35
+ 16481295130402928965223624965091828506529631770925981912487987233811901391354n,
36
+ 17911512007742433173433956238979622028159186641781974955249650899638270671335n,
37
+ 5186032540459307640178997905000265487821097518169449170073506338735292796958n,
38
+ 19685513117592528774434273738957742787082069361009067298107167967352389473358n,
39
+ 10912258653908058948673432107359060806004349811796220228800269957283778663923n,
40
+ 19880031465088514794850462701773174075421406509504511537647395867323147191667n,
41
+ 18344394662872801094289264994998928886741543433797415760903591256277307773470n,
42
+ 4023688209857926016730691838838984168964497755397275208674494663143007853450n,
43
+ 17055783594241143909439856980092099474877726697157440085377630370122026265082n,
44
+ 11977926289934490781035408984815805799047418332367129159688326349739029448709n,
45
+ 15234625627661323144444670162795779218620386251655457701229891659668427854091n,
46
+ 7411478947588169403968017607782514706815527017510001740123258574686422728877n,
47
+ 3160803355012082913337590211745210499441340098978812414661765381488126569348n,
48
+ ];
49
+
50
+ export enum Modules {
51
+ ExtData = 'vortex_ext_data',
52
+ Proof = 'vortex_proof',
53
+ Vortex = 'vortex',
54
+ }
55
+
56
+ export const ROOT_HISTORY_SIZE = 100;
57
+
58
+ export const MERKLE_TREE_HEIGHT = 26;
59
+
60
+ export const ERROR_CODES = {
61
+ 0: 'Invalid allowed deposit value',
62
+ 1: 'Merkle tree overflow',
63
+ 2: 'Proof root not known',
64
+ 3: 'Invalid Poseidon input',
65
+ 4: 'Invalid proof',
66
+ 5: 'Invalid proof vortex',
67
+ 6: 'Invalid address',
68
+ 7: 'Invalid zero value',
69
+ 8: 'Invalid ext data hash',
70
+ 9: 'Invalid ext data value',
71
+ 10: 'Invalid public value',
72
+ 11: 'Nullifier already spent',
73
+ 12: 'Invalid deposit value',
74
+ 13: 'Invalid relayer',
75
+ 14: 'Invalid output flag',
76
+ };
77
+
78
+ export const VORTEX_PACKAGE_ID =
79
+ '0x178934e5693d18a8fe9106c5590bb034c717035a94fda19472ca6d989c29f4b3';
80
+
81
+ export const UPGRADE_CAP =
82
+ '0x20aa94b46c4297aa07fb5789bc0350a32433933cb47a5392727b6eff73dc3f95';
83
+
84
+ export const VORTEX_POOL_OBJECT_ID =
85
+ '0x3a928257e6842ee56607c010162767e081a2756abd9ae4b039ce7c487db49c9f';
86
+
87
+ export const REGISTRY_OBJECT_ID =
88
+ '0x55b4b0d3e837937de4438fa70470da9fea8d72627458d68c1195a91b2769867f';
89
+
90
+ export const INITIAL_SHARED_VERSION = '4';
91
+
92
+ export const LSK_FETCH_OFFSET = 'fetch_offset';
93
+
94
+ export const LSK_ENCRYPTED_OUTPUTS = 'encrypted_outputs';
95
+
96
+ export const VORTEX_SIGNATURE_DOMAIN = 'VORTEXFI.XYZ';
97
+
98
+ export const TREASURY_ADDRESS =
99
+ '0x894261575b948c035d002adc3ca4d73c683c01a1bfafac183870940bf9afef1a';
100
+
101
+ // 0.5% deposit fee
102
+ export const DEPOSIT_FEE_IN_BASIS_POINTS = 50n;
103
+
104
+ export const BASIS_POINTS = 10_000n;