@atomiqlabs/chain-starknet 4.0.0-dev.26 → 4.0.0-dev.28

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 (154) hide show
  1. package/LICENSE +201 -201
  2. package/dist/index.d.ts +39 -39
  3. package/dist/index.js +55 -55
  4. package/dist/starknet/StarknetChainType.d.ts +13 -13
  5. package/dist/starknet/StarknetChainType.js +2 -2
  6. package/dist/starknet/StarknetInitializer.d.ts +28 -28
  7. package/dist/starknet/StarknetInitializer.js +69 -69
  8. package/dist/starknet/btcrelay/BtcRelayAbi.d.ts +250 -250
  9. package/dist/starknet/btcrelay/BtcRelayAbi.js +341 -341
  10. package/dist/starknet/btcrelay/StarknetBtcRelay.d.ts +186 -186
  11. package/dist/starknet/btcrelay/StarknetBtcRelay.js +379 -379
  12. package/dist/starknet/btcrelay/headers/StarknetBtcHeader.d.ts +31 -31
  13. package/dist/starknet/btcrelay/headers/StarknetBtcHeader.js +74 -74
  14. package/dist/starknet/btcrelay/headers/StarknetBtcStoredHeader.d.ts +51 -51
  15. package/dist/starknet/btcrelay/headers/StarknetBtcStoredHeader.js +113 -113
  16. package/dist/starknet/chain/StarknetAction.d.ts +19 -19
  17. package/dist/starknet/chain/StarknetAction.js +73 -73
  18. package/dist/starknet/chain/StarknetChainInterface.d.ts +54 -54
  19. package/dist/starknet/chain/StarknetChainInterface.js +97 -97
  20. package/dist/starknet/chain/StarknetModule.d.ts +9 -9
  21. package/dist/starknet/chain/StarknetModule.js +13 -13
  22. package/dist/starknet/chain/modules/ERC20Abi.d.ts +755 -755
  23. package/dist/starknet/chain/modules/ERC20Abi.js +1032 -1032
  24. package/dist/starknet/chain/modules/StarknetAccounts.d.ts +6 -6
  25. package/dist/starknet/chain/modules/StarknetAccounts.js +24 -24
  26. package/dist/starknet/chain/modules/StarknetAddresses.d.ts +9 -9
  27. package/dist/starknet/chain/modules/StarknetAddresses.js +26 -26
  28. package/dist/starknet/chain/modules/StarknetBlocks.d.ts +20 -20
  29. package/dist/starknet/chain/modules/StarknetBlocks.js +64 -64
  30. package/dist/starknet/chain/modules/StarknetEvents.d.ts +44 -44
  31. package/dist/starknet/chain/modules/StarknetEvents.js +88 -88
  32. package/dist/starknet/chain/modules/StarknetFees.d.ts +82 -82
  33. package/dist/starknet/chain/modules/StarknetFees.js +121 -121
  34. package/dist/starknet/chain/modules/StarknetSignatures.d.ts +29 -29
  35. package/dist/starknet/chain/modules/StarknetSignatures.js +72 -72
  36. package/dist/starknet/chain/modules/StarknetTokens.d.ts +69 -69
  37. package/dist/starknet/chain/modules/StarknetTokens.js +102 -102
  38. package/dist/starknet/chain/modules/StarknetTransactions.d.ts +111 -110
  39. package/dist/starknet/chain/modules/StarknetTransactions.js +359 -351
  40. package/dist/starknet/contract/StarknetContractBase.d.ts +13 -13
  41. package/dist/starknet/contract/StarknetContractBase.js +20 -20
  42. package/dist/starknet/contract/StarknetContractModule.d.ts +8 -8
  43. package/dist/starknet/contract/StarknetContractModule.js +11 -11
  44. package/dist/starknet/contract/modules/StarknetContractEvents.d.ts +51 -51
  45. package/dist/starknet/contract/modules/StarknetContractEvents.js +97 -97
  46. package/dist/starknet/events/StarknetChainEvents.d.ts +21 -21
  47. package/dist/starknet/events/StarknetChainEvents.js +52 -52
  48. package/dist/starknet/events/StarknetChainEventsBrowser.d.ts +84 -84
  49. package/dist/starknet/events/StarknetChainEventsBrowser.js +307 -307
  50. package/dist/starknet/provider/RpcProviderWithRetries.d.ts +41 -41
  51. package/dist/starknet/provider/RpcProviderWithRetries.js +70 -70
  52. package/dist/starknet/spv_swap/SpvVaultContractAbi.d.ts +488 -488
  53. package/dist/starknet/spv_swap/SpvVaultContractAbi.js +656 -656
  54. package/dist/starknet/spv_swap/StarknetSpvVaultContract.d.ts +89 -89
  55. package/dist/starknet/spv_swap/StarknetSpvVaultContract.js +477 -477
  56. package/dist/starknet/spv_swap/StarknetSpvVaultData.d.ts +49 -49
  57. package/dist/starknet/spv_swap/StarknetSpvVaultData.js +145 -145
  58. package/dist/starknet/spv_swap/StarknetSpvWithdrawalData.d.ts +25 -25
  59. package/dist/starknet/spv_swap/StarknetSpvWithdrawalData.js +72 -72
  60. package/dist/starknet/swaps/EscrowManagerAbi.d.ts +431 -431
  61. package/dist/starknet/swaps/EscrowManagerAbi.js +583 -583
  62. package/dist/starknet/swaps/StarknetSwapContract.d.ts +197 -197
  63. package/dist/starknet/swaps/StarknetSwapContract.js +440 -440
  64. package/dist/starknet/swaps/StarknetSwapData.d.ts +74 -74
  65. package/dist/starknet/swaps/StarknetSwapData.js +325 -325
  66. package/dist/starknet/swaps/StarknetSwapModule.d.ts +10 -10
  67. package/dist/starknet/swaps/StarknetSwapModule.js +11 -11
  68. package/dist/starknet/swaps/handlers/IHandler.d.ts +13 -13
  69. package/dist/starknet/swaps/handlers/IHandler.js +2 -2
  70. package/dist/starknet/swaps/handlers/claim/ClaimHandlers.d.ts +13 -13
  71. package/dist/starknet/swaps/handlers/claim/ClaimHandlers.js +13 -13
  72. package/dist/starknet/swaps/handlers/claim/HashlockClaimHandler.d.ts +21 -21
  73. package/dist/starknet/swaps/handlers/claim/HashlockClaimHandler.js +44 -44
  74. package/dist/starknet/swaps/handlers/claim/btc/BitcoinNoncedOutputClaimHandler.d.ts +24 -24
  75. package/dist/starknet/swaps/handlers/claim/btc/BitcoinNoncedOutputClaimHandler.js +48 -48
  76. package/dist/starknet/swaps/handlers/claim/btc/BitcoinOutputClaimHandler.d.ts +25 -25
  77. package/dist/starknet/swaps/handlers/claim/btc/BitcoinOutputClaimHandler.js +40 -40
  78. package/dist/starknet/swaps/handlers/claim/btc/BitcoinTxIdClaimHandler.d.ts +20 -20
  79. package/dist/starknet/swaps/handlers/claim/btc/BitcoinTxIdClaimHandler.js +30 -30
  80. package/dist/starknet/swaps/handlers/claim/btc/IBitcoinClaimHandler.d.ts +45 -45
  81. package/dist/starknet/swaps/handlers/claim/btc/IBitcoinClaimHandler.js +52 -52
  82. package/dist/starknet/swaps/handlers/refund/TimelockRefundHandler.d.ts +17 -17
  83. package/dist/starknet/swaps/handlers/refund/TimelockRefundHandler.js +27 -27
  84. package/dist/starknet/swaps/modules/StarknetLpVault.d.ts +69 -69
  85. package/dist/starknet/swaps/modules/StarknetLpVault.js +122 -122
  86. package/dist/starknet/swaps/modules/StarknetSwapClaim.d.ts +53 -53
  87. package/dist/starknet/swaps/modules/StarknetSwapClaim.js +100 -100
  88. package/dist/starknet/swaps/modules/StarknetSwapInit.d.ts +94 -94
  89. package/dist/starknet/swaps/modules/StarknetSwapInit.js +235 -235
  90. package/dist/starknet/swaps/modules/StarknetSwapRefund.d.ts +62 -62
  91. package/dist/starknet/swaps/modules/StarknetSwapRefund.js +128 -128
  92. package/dist/starknet/wallet/StarknetBrowserSigner.d.ts +5 -5
  93. package/dist/starknet/wallet/StarknetBrowserSigner.js +11 -11
  94. package/dist/starknet/wallet/StarknetKeypairWallet.d.ts +7 -7
  95. package/dist/starknet/wallet/StarknetKeypairWallet.js +35 -35
  96. package/dist/starknet/wallet/StarknetPersistentSigner.d.ts +33 -33
  97. package/dist/starknet/wallet/StarknetPersistentSigner.js +248 -243
  98. package/dist/starknet/wallet/StarknetSigner.d.ts +18 -18
  99. package/dist/starknet/wallet/StarknetSigner.js +69 -69
  100. package/dist/starknet/wallet/accounts/StarknetKeypairWallet.d.ts +7 -7
  101. package/dist/starknet/wallet/accounts/StarknetKeypairWallet.js +35 -35
  102. package/dist/utils/Utils.d.ts +39 -39
  103. package/dist/utils/Utils.js +264 -264
  104. package/package.json +45 -45
  105. package/src/index.ts +48 -48
  106. package/src/starknet/StarknetChainType.ts +28 -28
  107. package/src/starknet/StarknetInitializer.ts +110 -110
  108. package/src/starknet/btcrelay/BtcRelayAbi.ts +338 -338
  109. package/src/starknet/btcrelay/StarknetBtcRelay.ts +494 -494
  110. package/src/starknet/btcrelay/headers/StarknetBtcHeader.ts +100 -100
  111. package/src/starknet/btcrelay/headers/StarknetBtcStoredHeader.ts +141 -141
  112. package/src/starknet/chain/StarknetAction.ts +85 -85
  113. package/src/starknet/chain/StarknetChainInterface.ts +165 -165
  114. package/src/starknet/chain/StarknetModule.ts +19 -19
  115. package/src/starknet/chain/modules/ERC20Abi.ts +1029 -1029
  116. package/src/starknet/chain/modules/StarknetAccounts.ts +25 -25
  117. package/src/starknet/chain/modules/StarknetAddresses.ts +22 -22
  118. package/src/starknet/chain/modules/StarknetBlocks.ts +75 -75
  119. package/src/starknet/chain/modules/StarknetEvents.ts +104 -104
  120. package/src/starknet/chain/modules/StarknetFees.ts +162 -162
  121. package/src/starknet/chain/modules/StarknetSignatures.ts +91 -91
  122. package/src/starknet/chain/modules/StarknetTokens.ts +120 -120
  123. package/src/starknet/chain/modules/StarknetTransactions.ts +399 -392
  124. package/src/starknet/contract/StarknetContractBase.ts +30 -30
  125. package/src/starknet/contract/StarknetContractModule.ts +16 -16
  126. package/src/starknet/contract/modules/StarknetContractEvents.ts +134 -134
  127. package/src/starknet/events/StarknetChainEvents.ts +67 -67
  128. package/src/starknet/events/StarknetChainEventsBrowser.ts +420 -420
  129. package/src/starknet/provider/RpcProviderWithRetries.ts +83 -83
  130. package/src/starknet/spv_swap/SpvVaultContractAbi.ts +656 -656
  131. package/src/starknet/spv_swap/StarknetSpvVaultContract.ts +591 -591
  132. package/src/starknet/spv_swap/StarknetSpvVaultData.ts +195 -195
  133. package/src/starknet/spv_swap/StarknetSpvWithdrawalData.ts +79 -79
  134. package/src/starknet/swaps/EscrowManagerAbi.ts +582 -582
  135. package/src/starknet/swaps/StarknetSwapContract.ts +668 -668
  136. package/src/starknet/swaps/StarknetSwapData.ts +455 -455
  137. package/src/starknet/swaps/StarknetSwapModule.ts +17 -17
  138. package/src/starknet/swaps/handlers/IHandler.ts +20 -20
  139. package/src/starknet/swaps/handlers/claim/ClaimHandlers.ts +23 -23
  140. package/src/starknet/swaps/handlers/claim/HashlockClaimHandler.ts +53 -53
  141. package/src/starknet/swaps/handlers/claim/btc/BitcoinNoncedOutputClaimHandler.ts +73 -73
  142. package/src/starknet/swaps/handlers/claim/btc/BitcoinOutputClaimHandler.ts +67 -67
  143. package/src/starknet/swaps/handlers/claim/btc/BitcoinTxIdClaimHandler.ts +50 -50
  144. package/src/starknet/swaps/handlers/claim/btc/IBitcoinClaimHandler.ts +102 -102
  145. package/src/starknet/swaps/handlers/refund/TimelockRefundHandler.ts +38 -38
  146. package/src/starknet/swaps/modules/StarknetLpVault.ts +147 -147
  147. package/src/starknet/swaps/modules/StarknetSwapClaim.ts +141 -141
  148. package/src/starknet/swaps/modules/StarknetSwapInit.ts +300 -300
  149. package/src/starknet/swaps/modules/StarknetSwapRefund.ts +196 -196
  150. package/src/starknet/wallet/StarknetBrowserSigner.ts +11 -11
  151. package/src/starknet/wallet/StarknetPersistentSigner.ts +314 -310
  152. package/src/starknet/wallet/StarknetSigner.ts +84 -84
  153. package/src/starknet/wallet/accounts/StarknetKeypairWallet.ts +44 -44
  154. package/src/utils/Utils.ts +262 -262
@@ -1,431 +1,431 @@
1
- export declare const EscrowManagerAbi: readonly [{
2
- readonly type: "impl";
3
- readonly name: "EscrowManagerImpl";
4
- readonly interface_name: "escrow_manager::IEscrowManager";
5
- }, {
6
- readonly type: "struct";
7
- readonly name: "core::integer::u256";
8
- readonly members: readonly [{
9
- readonly name: "low";
10
- readonly type: "core::integer::u128";
11
- }, {
12
- readonly name: "high";
13
- readonly type: "core::integer::u128";
14
- }];
15
- }, {
16
- readonly type: "struct";
17
- readonly name: "escrow_manager::structs::escrow::EscrowExecution";
18
- readonly members: readonly [{
19
- readonly name: "hash";
20
- readonly type: "core::felt252";
21
- }, {
22
- readonly name: "expiry";
23
- readonly type: "core::integer::u64";
24
- }, {
25
- readonly name: "fee";
26
- readonly type: "core::integer::u256";
27
- }];
28
- }, {
29
- readonly type: "enum";
30
- readonly name: "core::option::Option::<escrow_manager::structs::escrow::EscrowExecution>";
31
- readonly variants: readonly [{
32
- readonly name: "Some";
33
- readonly type: "escrow_manager::structs::escrow::EscrowExecution";
34
- }, {
35
- readonly name: "None";
36
- readonly type: "()";
37
- }];
38
- }, {
39
- readonly type: "struct";
40
- readonly name: "escrow_manager::structs::escrow::EscrowData";
41
- readonly members: readonly [{
42
- readonly name: "offerer";
43
- readonly type: "core::starknet::contract_address::ContractAddress";
44
- }, {
45
- readonly name: "claimer";
46
- readonly type: "core::starknet::contract_address::ContractAddress";
47
- }, {
48
- readonly name: "token";
49
- readonly type: "core::starknet::contract_address::ContractAddress";
50
- }, {
51
- readonly name: "refund_handler";
52
- readonly type: "core::starknet::contract_address::ContractAddress";
53
- }, {
54
- readonly name: "claim_handler";
55
- readonly type: "core::starknet::contract_address::ContractAddress";
56
- }, {
57
- readonly name: "flags";
58
- readonly type: "core::integer::u128";
59
- }, {
60
- readonly name: "claim_data";
61
- readonly type: "core::felt252";
62
- }, {
63
- readonly name: "refund_data";
64
- readonly type: "core::felt252";
65
- }, {
66
- readonly name: "amount";
67
- readonly type: "core::integer::u256";
68
- }, {
69
- readonly name: "fee_token";
70
- readonly type: "core::starknet::contract_address::ContractAddress";
71
- }, {
72
- readonly name: "security_deposit";
73
- readonly type: "core::integer::u256";
74
- }, {
75
- readonly name: "claimer_bounty";
76
- readonly type: "core::integer::u256";
77
- }, {
78
- readonly name: "success_action";
79
- readonly type: "core::option::Option::<escrow_manager::structs::escrow::EscrowExecution>";
80
- }];
81
- }, {
82
- readonly type: "struct";
83
- readonly name: "core::array::Span::<core::felt252>";
84
- readonly members: readonly [{
85
- readonly name: "snapshot";
86
- readonly type: "@core::array::Array::<core::felt252>";
87
- }];
88
- }, {
89
- readonly type: "interface";
90
- readonly name: "escrow_manager::IEscrowManager";
91
- readonly items: readonly [{
92
- readonly type: "function";
93
- readonly name: "initialize";
94
- readonly inputs: readonly [{
95
- readonly name: "escrow";
96
- readonly type: "escrow_manager::structs::escrow::EscrowData";
97
- }, {
98
- readonly name: "signature";
99
- readonly type: "core::array::Array::<core::felt252>";
100
- }, {
101
- readonly name: "timeout";
102
- readonly type: "core::integer::u64";
103
- }, {
104
- readonly name: "extra_data";
105
- readonly type: "core::array::Span::<core::felt252>";
106
- }];
107
- readonly outputs: readonly [];
108
- readonly state_mutability: "external";
109
- }, {
110
- readonly type: "function";
111
- readonly name: "claim";
112
- readonly inputs: readonly [{
113
- readonly name: "escrow";
114
- readonly type: "escrow_manager::structs::escrow::EscrowData";
115
- }, {
116
- readonly name: "witness";
117
- readonly type: "core::array::Array::<core::felt252>";
118
- }];
119
- readonly outputs: readonly [];
120
- readonly state_mutability: "external";
121
- }, {
122
- readonly type: "function";
123
- readonly name: "refund";
124
- readonly inputs: readonly [{
125
- readonly name: "escrow";
126
- readonly type: "escrow_manager::structs::escrow::EscrowData";
127
- }, {
128
- readonly name: "witness";
129
- readonly type: "core::array::Array::<core::felt252>";
130
- }];
131
- readonly outputs: readonly [];
132
- readonly state_mutability: "external";
133
- }, {
134
- readonly type: "function";
135
- readonly name: "cooperative_refund";
136
- readonly inputs: readonly [{
137
- readonly name: "escrow";
138
- readonly type: "escrow_manager::structs::escrow::EscrowData";
139
- }, {
140
- readonly name: "signature";
141
- readonly type: "core::array::Array::<core::felt252>";
142
- }, {
143
- readonly name: "timeout";
144
- readonly type: "core::integer::u64";
145
- }];
146
- readonly outputs: readonly [];
147
- readonly state_mutability: "external";
148
- }];
149
- }, {
150
- readonly type: "impl";
151
- readonly name: "LPVaultImpl";
152
- readonly interface_name: "escrow_manager::components::lp_vault::ILPVault";
153
- }, {
154
- readonly type: "struct";
155
- readonly name: "core::array::Span::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
156
- readonly members: readonly [{
157
- readonly name: "snapshot";
158
- readonly type: "@core::array::Array::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
159
- }];
160
- }, {
161
- readonly type: "interface";
162
- readonly name: "escrow_manager::components::lp_vault::ILPVault";
163
- readonly items: readonly [{
164
- readonly type: "function";
165
- readonly name: "deposit";
166
- readonly inputs: readonly [{
167
- readonly name: "token";
168
- readonly type: "core::starknet::contract_address::ContractAddress";
169
- }, {
170
- readonly name: "amount";
171
- readonly type: "core::integer::u256";
172
- }];
173
- readonly outputs: readonly [];
174
- readonly state_mutability: "external";
175
- }, {
176
- readonly type: "function";
177
- readonly name: "withdraw";
178
- readonly inputs: readonly [{
179
- readonly name: "token";
180
- readonly type: "core::starknet::contract_address::ContractAddress";
181
- }, {
182
- readonly name: "amount";
183
- readonly type: "core::integer::u256";
184
- }, {
185
- readonly name: "destination";
186
- readonly type: "core::starknet::contract_address::ContractAddress";
187
- }];
188
- readonly outputs: readonly [];
189
- readonly state_mutability: "external";
190
- }, {
191
- readonly type: "function";
192
- readonly name: "get_balance";
193
- readonly inputs: readonly [{
194
- readonly name: "data";
195
- readonly type: "core::array::Span::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
196
- }];
197
- readonly outputs: readonly [{
198
- readonly type: "core::array::Array::<core::integer::u256>";
199
- }];
200
- readonly state_mutability: "view";
201
- }];
202
- }, {
203
- readonly type: "impl";
204
- readonly name: "ReputationTrackerImpl";
205
- readonly interface_name: "escrow_manager::components::reputation::IReputationTracker";
206
- }, {
207
- readonly type: "struct";
208
- readonly name: "core::array::Span::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
209
- readonly members: readonly [{
210
- readonly name: "snapshot";
211
- readonly type: "@core::array::Array::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
212
- }];
213
- }, {
214
- readonly type: "struct";
215
- readonly name: "escrow_manager::state::reputation::Reputation";
216
- readonly members: readonly [{
217
- readonly name: "amount";
218
- readonly type: "core::integer::u256";
219
- }, {
220
- readonly name: "count";
221
- readonly type: "core::integer::u128";
222
- }];
223
- }, {
224
- readonly type: "interface";
225
- readonly name: "escrow_manager::components::reputation::IReputationTracker";
226
- readonly items: readonly [{
227
- readonly type: "function";
228
- readonly name: "get_reputation";
229
- readonly inputs: readonly [{
230
- readonly name: "data";
231
- readonly type: "core::array::Span::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
232
- }];
233
- readonly outputs: readonly [{
234
- readonly type: "core::array::Array::<[escrow_manager::state::reputation::Reputation; 3]>";
235
- }];
236
- readonly state_mutability: "view";
237
- }];
238
- }, {
239
- readonly type: "impl";
240
- readonly name: "EscrowStorageImpl";
241
- readonly interface_name: "escrow_manager::components::escrow_storage::IEscrowStorage";
242
- }, {
243
- readonly type: "struct";
244
- readonly name: "escrow_manager::state::escrow::EscrowState";
245
- readonly members: readonly [{
246
- readonly name: "init_blockheight";
247
- readonly type: "core::integer::u64";
248
- }, {
249
- readonly name: "finish_blockheight";
250
- readonly type: "core::integer::u64";
251
- }, {
252
- readonly name: "state";
253
- readonly type: "core::integer::u8";
254
- }];
255
- }, {
256
- readonly type: "struct";
257
- readonly name: "core::array::Span::<escrow_manager::state::escrow::EscrowState>";
258
- readonly members: readonly [{
259
- readonly name: "snapshot";
260
- readonly type: "@core::array::Array::<escrow_manager::state::escrow::EscrowState>";
261
- }];
262
- }, {
263
- readonly type: "interface";
264
- readonly name: "escrow_manager::components::escrow_storage::IEscrowStorage";
265
- readonly items: readonly [{
266
- readonly type: "function";
267
- readonly name: "get_state";
268
- readonly inputs: readonly [{
269
- readonly name: "escrow";
270
- readonly type: "escrow_manager::structs::escrow::EscrowData";
271
- }];
272
- readonly outputs: readonly [{
273
- readonly type: "escrow_manager::state::escrow::EscrowState";
274
- }];
275
- readonly state_mutability: "view";
276
- }, {
277
- readonly type: "function";
278
- readonly name: "get_hash_state";
279
- readonly inputs: readonly [{
280
- readonly name: "escrow_hash";
281
- readonly type: "core::felt252";
282
- }];
283
- readonly outputs: readonly [{
284
- readonly type: "escrow_manager::state::escrow::EscrowState";
285
- }];
286
- readonly state_mutability: "view";
287
- }, {
288
- readonly type: "function";
289
- readonly name: "get_hash_state_multiple";
290
- readonly inputs: readonly [{
291
- readonly name: "escrow_hashes";
292
- readonly type: "core::array::Span::<core::felt252>";
293
- }];
294
- readonly outputs: readonly [{
295
- readonly type: "core::array::Span::<escrow_manager::state::escrow::EscrowState>";
296
- }];
297
- readonly state_mutability: "view";
298
- }];
299
- }, {
300
- readonly type: "event";
301
- readonly name: "escrow_manager::components::lp_vault::lp_vault::Event";
302
- readonly kind: "enum";
303
- readonly variants: readonly [];
304
- }, {
305
- readonly type: "event";
306
- readonly name: "escrow_manager::components::reputation::reputation::Event";
307
- readonly kind: "enum";
308
- readonly variants: readonly [];
309
- }, {
310
- readonly type: "event";
311
- readonly name: "escrow_manager::components::escrow_storage::escrow_storage::Event";
312
- readonly kind: "enum";
313
- readonly variants: readonly [];
314
- }, {
315
- readonly type: "event";
316
- readonly name: "escrow_manager::events::Initialize";
317
- readonly kind: "struct";
318
- readonly members: readonly [{
319
- readonly name: "offerer";
320
- readonly type: "core::starknet::contract_address::ContractAddress";
321
- readonly kind: "key";
322
- }, {
323
- readonly name: "claimer";
324
- readonly type: "core::starknet::contract_address::ContractAddress";
325
- readonly kind: "key";
326
- }, {
327
- readonly name: "claim_data";
328
- readonly type: "core::felt252";
329
- readonly kind: "key";
330
- }, {
331
- readonly name: "escrow_hash";
332
- readonly type: "core::felt252";
333
- readonly kind: "key";
334
- }, {
335
- readonly name: "claim_handler";
336
- readonly type: "core::starknet::contract_address::ContractAddress";
337
- readonly kind: "data";
338
- }, {
339
- readonly name: "refund_handler";
340
- readonly type: "core::starknet::contract_address::ContractAddress";
341
- readonly kind: "data";
342
- }];
343
- }, {
344
- readonly type: "event";
345
- readonly name: "escrow_manager::events::Claim";
346
- readonly kind: "struct";
347
- readonly members: readonly [{
348
- readonly name: "offerer";
349
- readonly type: "core::starknet::contract_address::ContractAddress";
350
- readonly kind: "key";
351
- }, {
352
- readonly name: "claimer";
353
- readonly type: "core::starknet::contract_address::ContractAddress";
354
- readonly kind: "key";
355
- }, {
356
- readonly name: "claim_data";
357
- readonly type: "core::felt252";
358
- readonly kind: "key";
359
- }, {
360
- readonly name: "escrow_hash";
361
- readonly type: "core::felt252";
362
- readonly kind: "key";
363
- }, {
364
- readonly name: "witness_result";
365
- readonly type: "core::array::Span::<core::felt252>";
366
- readonly kind: "data";
367
- }, {
368
- readonly name: "claim_handler";
369
- readonly type: "core::starknet::contract_address::ContractAddress";
370
- readonly kind: "data";
371
- }];
372
- }, {
373
- readonly type: "event";
374
- readonly name: "escrow_manager::events::Refund";
375
- readonly kind: "struct";
376
- readonly members: readonly [{
377
- readonly name: "offerer";
378
- readonly type: "core::starknet::contract_address::ContractAddress";
379
- readonly kind: "key";
380
- }, {
381
- readonly name: "claimer";
382
- readonly type: "core::starknet::contract_address::ContractAddress";
383
- readonly kind: "key";
384
- }, {
385
- readonly name: "claim_data";
386
- readonly type: "core::felt252";
387
- readonly kind: "key";
388
- }, {
389
- readonly name: "escrow_hash";
390
- readonly type: "core::felt252";
391
- readonly kind: "key";
392
- }, {
393
- readonly name: "witness_result";
394
- readonly type: "core::array::Span::<core::felt252>";
395
- readonly kind: "data";
396
- }, {
397
- readonly name: "refund_handler";
398
- readonly type: "core::starknet::contract_address::ContractAddress";
399
- readonly kind: "data";
400
- }];
401
- }, {
402
- readonly type: "event";
403
- readonly name: "escrow_manager::EscrowManager::Event";
404
- readonly kind: "enum";
405
- readonly variants: readonly [{
406
- readonly name: "LPVaultEvent";
407
- readonly type: "escrow_manager::components::lp_vault::lp_vault::Event";
408
- readonly kind: "nested";
409
- }, {
410
- readonly name: "ReputationTrackerEvent";
411
- readonly type: "escrow_manager::components::reputation::reputation::Event";
412
- readonly kind: "nested";
413
- }, {
414
- readonly name: "EscrowStorageEvent";
415
- readonly type: "escrow_manager::components::escrow_storage::escrow_storage::Event";
416
- readonly kind: "nested";
417
- }, {
418
- readonly name: "Initialize";
419
- readonly type: "escrow_manager::events::Initialize";
420
- readonly kind: "nested";
421
- }, {
422
- readonly name: "Claim";
423
- readonly type: "escrow_manager::events::Claim";
424
- readonly kind: "nested";
425
- }, {
426
- readonly name: "Refund";
427
- readonly type: "escrow_manager::events::Refund";
428
- readonly kind: "nested";
429
- }];
430
- }];
431
- export type EscrowManagerAbiType = typeof EscrowManagerAbi;
1
+ export declare const EscrowManagerAbi: readonly [{
2
+ readonly type: "impl";
3
+ readonly name: "EscrowManagerImpl";
4
+ readonly interface_name: "escrow_manager::IEscrowManager";
5
+ }, {
6
+ readonly type: "struct";
7
+ readonly name: "core::integer::u256";
8
+ readonly members: readonly [{
9
+ readonly name: "low";
10
+ readonly type: "core::integer::u128";
11
+ }, {
12
+ readonly name: "high";
13
+ readonly type: "core::integer::u128";
14
+ }];
15
+ }, {
16
+ readonly type: "struct";
17
+ readonly name: "escrow_manager::structs::escrow::EscrowExecution";
18
+ readonly members: readonly [{
19
+ readonly name: "hash";
20
+ readonly type: "core::felt252";
21
+ }, {
22
+ readonly name: "expiry";
23
+ readonly type: "core::integer::u64";
24
+ }, {
25
+ readonly name: "fee";
26
+ readonly type: "core::integer::u256";
27
+ }];
28
+ }, {
29
+ readonly type: "enum";
30
+ readonly name: "core::option::Option::<escrow_manager::structs::escrow::EscrowExecution>";
31
+ readonly variants: readonly [{
32
+ readonly name: "Some";
33
+ readonly type: "escrow_manager::structs::escrow::EscrowExecution";
34
+ }, {
35
+ readonly name: "None";
36
+ readonly type: "()";
37
+ }];
38
+ }, {
39
+ readonly type: "struct";
40
+ readonly name: "escrow_manager::structs::escrow::EscrowData";
41
+ readonly members: readonly [{
42
+ readonly name: "offerer";
43
+ readonly type: "core::starknet::contract_address::ContractAddress";
44
+ }, {
45
+ readonly name: "claimer";
46
+ readonly type: "core::starknet::contract_address::ContractAddress";
47
+ }, {
48
+ readonly name: "token";
49
+ readonly type: "core::starknet::contract_address::ContractAddress";
50
+ }, {
51
+ readonly name: "refund_handler";
52
+ readonly type: "core::starknet::contract_address::ContractAddress";
53
+ }, {
54
+ readonly name: "claim_handler";
55
+ readonly type: "core::starknet::contract_address::ContractAddress";
56
+ }, {
57
+ readonly name: "flags";
58
+ readonly type: "core::integer::u128";
59
+ }, {
60
+ readonly name: "claim_data";
61
+ readonly type: "core::felt252";
62
+ }, {
63
+ readonly name: "refund_data";
64
+ readonly type: "core::felt252";
65
+ }, {
66
+ readonly name: "amount";
67
+ readonly type: "core::integer::u256";
68
+ }, {
69
+ readonly name: "fee_token";
70
+ readonly type: "core::starknet::contract_address::ContractAddress";
71
+ }, {
72
+ readonly name: "security_deposit";
73
+ readonly type: "core::integer::u256";
74
+ }, {
75
+ readonly name: "claimer_bounty";
76
+ readonly type: "core::integer::u256";
77
+ }, {
78
+ readonly name: "success_action";
79
+ readonly type: "core::option::Option::<escrow_manager::structs::escrow::EscrowExecution>";
80
+ }];
81
+ }, {
82
+ readonly type: "struct";
83
+ readonly name: "core::array::Span::<core::felt252>";
84
+ readonly members: readonly [{
85
+ readonly name: "snapshot";
86
+ readonly type: "@core::array::Array::<core::felt252>";
87
+ }];
88
+ }, {
89
+ readonly type: "interface";
90
+ readonly name: "escrow_manager::IEscrowManager";
91
+ readonly items: readonly [{
92
+ readonly type: "function";
93
+ readonly name: "initialize";
94
+ readonly inputs: readonly [{
95
+ readonly name: "escrow";
96
+ readonly type: "escrow_manager::structs::escrow::EscrowData";
97
+ }, {
98
+ readonly name: "signature";
99
+ readonly type: "core::array::Array::<core::felt252>";
100
+ }, {
101
+ readonly name: "timeout";
102
+ readonly type: "core::integer::u64";
103
+ }, {
104
+ readonly name: "extra_data";
105
+ readonly type: "core::array::Span::<core::felt252>";
106
+ }];
107
+ readonly outputs: readonly [];
108
+ readonly state_mutability: "external";
109
+ }, {
110
+ readonly type: "function";
111
+ readonly name: "claim";
112
+ readonly inputs: readonly [{
113
+ readonly name: "escrow";
114
+ readonly type: "escrow_manager::structs::escrow::EscrowData";
115
+ }, {
116
+ readonly name: "witness";
117
+ readonly type: "core::array::Array::<core::felt252>";
118
+ }];
119
+ readonly outputs: readonly [];
120
+ readonly state_mutability: "external";
121
+ }, {
122
+ readonly type: "function";
123
+ readonly name: "refund";
124
+ readonly inputs: readonly [{
125
+ readonly name: "escrow";
126
+ readonly type: "escrow_manager::structs::escrow::EscrowData";
127
+ }, {
128
+ readonly name: "witness";
129
+ readonly type: "core::array::Array::<core::felt252>";
130
+ }];
131
+ readonly outputs: readonly [];
132
+ readonly state_mutability: "external";
133
+ }, {
134
+ readonly type: "function";
135
+ readonly name: "cooperative_refund";
136
+ readonly inputs: readonly [{
137
+ readonly name: "escrow";
138
+ readonly type: "escrow_manager::structs::escrow::EscrowData";
139
+ }, {
140
+ readonly name: "signature";
141
+ readonly type: "core::array::Array::<core::felt252>";
142
+ }, {
143
+ readonly name: "timeout";
144
+ readonly type: "core::integer::u64";
145
+ }];
146
+ readonly outputs: readonly [];
147
+ readonly state_mutability: "external";
148
+ }];
149
+ }, {
150
+ readonly type: "impl";
151
+ readonly name: "LPVaultImpl";
152
+ readonly interface_name: "escrow_manager::components::lp_vault::ILPVault";
153
+ }, {
154
+ readonly type: "struct";
155
+ readonly name: "core::array::Span::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
156
+ readonly members: readonly [{
157
+ readonly name: "snapshot";
158
+ readonly type: "@core::array::Array::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
159
+ }];
160
+ }, {
161
+ readonly type: "interface";
162
+ readonly name: "escrow_manager::components::lp_vault::ILPVault";
163
+ readonly items: readonly [{
164
+ readonly type: "function";
165
+ readonly name: "deposit";
166
+ readonly inputs: readonly [{
167
+ readonly name: "token";
168
+ readonly type: "core::starknet::contract_address::ContractAddress";
169
+ }, {
170
+ readonly name: "amount";
171
+ readonly type: "core::integer::u256";
172
+ }];
173
+ readonly outputs: readonly [];
174
+ readonly state_mutability: "external";
175
+ }, {
176
+ readonly type: "function";
177
+ readonly name: "withdraw";
178
+ readonly inputs: readonly [{
179
+ readonly name: "token";
180
+ readonly type: "core::starknet::contract_address::ContractAddress";
181
+ }, {
182
+ readonly name: "amount";
183
+ readonly type: "core::integer::u256";
184
+ }, {
185
+ readonly name: "destination";
186
+ readonly type: "core::starknet::contract_address::ContractAddress";
187
+ }];
188
+ readonly outputs: readonly [];
189
+ readonly state_mutability: "external";
190
+ }, {
191
+ readonly type: "function";
192
+ readonly name: "get_balance";
193
+ readonly inputs: readonly [{
194
+ readonly name: "data";
195
+ readonly type: "core::array::Span::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
196
+ }];
197
+ readonly outputs: readonly [{
198
+ readonly type: "core::array::Array::<core::integer::u256>";
199
+ }];
200
+ readonly state_mutability: "view";
201
+ }];
202
+ }, {
203
+ readonly type: "impl";
204
+ readonly name: "ReputationTrackerImpl";
205
+ readonly interface_name: "escrow_manager::components::reputation::IReputationTracker";
206
+ }, {
207
+ readonly type: "struct";
208
+ readonly name: "core::array::Span::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
209
+ readonly members: readonly [{
210
+ readonly name: "snapshot";
211
+ readonly type: "@core::array::Array::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
212
+ }];
213
+ }, {
214
+ readonly type: "struct";
215
+ readonly name: "escrow_manager::state::reputation::Reputation";
216
+ readonly members: readonly [{
217
+ readonly name: "amount";
218
+ readonly type: "core::integer::u256";
219
+ }, {
220
+ readonly name: "count";
221
+ readonly type: "core::integer::u128";
222
+ }];
223
+ }, {
224
+ readonly type: "interface";
225
+ readonly name: "escrow_manager::components::reputation::IReputationTracker";
226
+ readonly items: readonly [{
227
+ readonly type: "function";
228
+ readonly name: "get_reputation";
229
+ readonly inputs: readonly [{
230
+ readonly name: "data";
231
+ readonly type: "core::array::Span::<(core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress, core::starknet::contract_address::ContractAddress)>";
232
+ }];
233
+ readonly outputs: readonly [{
234
+ readonly type: "core::array::Array::<[escrow_manager::state::reputation::Reputation; 3]>";
235
+ }];
236
+ readonly state_mutability: "view";
237
+ }];
238
+ }, {
239
+ readonly type: "impl";
240
+ readonly name: "EscrowStorageImpl";
241
+ readonly interface_name: "escrow_manager::components::escrow_storage::IEscrowStorage";
242
+ }, {
243
+ readonly type: "struct";
244
+ readonly name: "escrow_manager::state::escrow::EscrowState";
245
+ readonly members: readonly [{
246
+ readonly name: "init_blockheight";
247
+ readonly type: "core::integer::u64";
248
+ }, {
249
+ readonly name: "finish_blockheight";
250
+ readonly type: "core::integer::u64";
251
+ }, {
252
+ readonly name: "state";
253
+ readonly type: "core::integer::u8";
254
+ }];
255
+ }, {
256
+ readonly type: "struct";
257
+ readonly name: "core::array::Span::<escrow_manager::state::escrow::EscrowState>";
258
+ readonly members: readonly [{
259
+ readonly name: "snapshot";
260
+ readonly type: "@core::array::Array::<escrow_manager::state::escrow::EscrowState>";
261
+ }];
262
+ }, {
263
+ readonly type: "interface";
264
+ readonly name: "escrow_manager::components::escrow_storage::IEscrowStorage";
265
+ readonly items: readonly [{
266
+ readonly type: "function";
267
+ readonly name: "get_state";
268
+ readonly inputs: readonly [{
269
+ readonly name: "escrow";
270
+ readonly type: "escrow_manager::structs::escrow::EscrowData";
271
+ }];
272
+ readonly outputs: readonly [{
273
+ readonly type: "escrow_manager::state::escrow::EscrowState";
274
+ }];
275
+ readonly state_mutability: "view";
276
+ }, {
277
+ readonly type: "function";
278
+ readonly name: "get_hash_state";
279
+ readonly inputs: readonly [{
280
+ readonly name: "escrow_hash";
281
+ readonly type: "core::felt252";
282
+ }];
283
+ readonly outputs: readonly [{
284
+ readonly type: "escrow_manager::state::escrow::EscrowState";
285
+ }];
286
+ readonly state_mutability: "view";
287
+ }, {
288
+ readonly type: "function";
289
+ readonly name: "get_hash_state_multiple";
290
+ readonly inputs: readonly [{
291
+ readonly name: "escrow_hashes";
292
+ readonly type: "core::array::Span::<core::felt252>";
293
+ }];
294
+ readonly outputs: readonly [{
295
+ readonly type: "core::array::Span::<escrow_manager::state::escrow::EscrowState>";
296
+ }];
297
+ readonly state_mutability: "view";
298
+ }];
299
+ }, {
300
+ readonly type: "event";
301
+ readonly name: "escrow_manager::components::lp_vault::lp_vault::Event";
302
+ readonly kind: "enum";
303
+ readonly variants: readonly [];
304
+ }, {
305
+ readonly type: "event";
306
+ readonly name: "escrow_manager::components::reputation::reputation::Event";
307
+ readonly kind: "enum";
308
+ readonly variants: readonly [];
309
+ }, {
310
+ readonly type: "event";
311
+ readonly name: "escrow_manager::components::escrow_storage::escrow_storage::Event";
312
+ readonly kind: "enum";
313
+ readonly variants: readonly [];
314
+ }, {
315
+ readonly type: "event";
316
+ readonly name: "escrow_manager::events::Initialize";
317
+ readonly kind: "struct";
318
+ readonly members: readonly [{
319
+ readonly name: "offerer";
320
+ readonly type: "core::starknet::contract_address::ContractAddress";
321
+ readonly kind: "key";
322
+ }, {
323
+ readonly name: "claimer";
324
+ readonly type: "core::starknet::contract_address::ContractAddress";
325
+ readonly kind: "key";
326
+ }, {
327
+ readonly name: "claim_data";
328
+ readonly type: "core::felt252";
329
+ readonly kind: "key";
330
+ }, {
331
+ readonly name: "escrow_hash";
332
+ readonly type: "core::felt252";
333
+ readonly kind: "key";
334
+ }, {
335
+ readonly name: "claim_handler";
336
+ readonly type: "core::starknet::contract_address::ContractAddress";
337
+ readonly kind: "data";
338
+ }, {
339
+ readonly name: "refund_handler";
340
+ readonly type: "core::starknet::contract_address::ContractAddress";
341
+ readonly kind: "data";
342
+ }];
343
+ }, {
344
+ readonly type: "event";
345
+ readonly name: "escrow_manager::events::Claim";
346
+ readonly kind: "struct";
347
+ readonly members: readonly [{
348
+ readonly name: "offerer";
349
+ readonly type: "core::starknet::contract_address::ContractAddress";
350
+ readonly kind: "key";
351
+ }, {
352
+ readonly name: "claimer";
353
+ readonly type: "core::starknet::contract_address::ContractAddress";
354
+ readonly kind: "key";
355
+ }, {
356
+ readonly name: "claim_data";
357
+ readonly type: "core::felt252";
358
+ readonly kind: "key";
359
+ }, {
360
+ readonly name: "escrow_hash";
361
+ readonly type: "core::felt252";
362
+ readonly kind: "key";
363
+ }, {
364
+ readonly name: "witness_result";
365
+ readonly type: "core::array::Span::<core::felt252>";
366
+ readonly kind: "data";
367
+ }, {
368
+ readonly name: "claim_handler";
369
+ readonly type: "core::starknet::contract_address::ContractAddress";
370
+ readonly kind: "data";
371
+ }];
372
+ }, {
373
+ readonly type: "event";
374
+ readonly name: "escrow_manager::events::Refund";
375
+ readonly kind: "struct";
376
+ readonly members: readonly [{
377
+ readonly name: "offerer";
378
+ readonly type: "core::starknet::contract_address::ContractAddress";
379
+ readonly kind: "key";
380
+ }, {
381
+ readonly name: "claimer";
382
+ readonly type: "core::starknet::contract_address::ContractAddress";
383
+ readonly kind: "key";
384
+ }, {
385
+ readonly name: "claim_data";
386
+ readonly type: "core::felt252";
387
+ readonly kind: "key";
388
+ }, {
389
+ readonly name: "escrow_hash";
390
+ readonly type: "core::felt252";
391
+ readonly kind: "key";
392
+ }, {
393
+ readonly name: "witness_result";
394
+ readonly type: "core::array::Span::<core::felt252>";
395
+ readonly kind: "data";
396
+ }, {
397
+ readonly name: "refund_handler";
398
+ readonly type: "core::starknet::contract_address::ContractAddress";
399
+ readonly kind: "data";
400
+ }];
401
+ }, {
402
+ readonly type: "event";
403
+ readonly name: "escrow_manager::EscrowManager::Event";
404
+ readonly kind: "enum";
405
+ readonly variants: readonly [{
406
+ readonly name: "LPVaultEvent";
407
+ readonly type: "escrow_manager::components::lp_vault::lp_vault::Event";
408
+ readonly kind: "nested";
409
+ }, {
410
+ readonly name: "ReputationTrackerEvent";
411
+ readonly type: "escrow_manager::components::reputation::reputation::Event";
412
+ readonly kind: "nested";
413
+ }, {
414
+ readonly name: "EscrowStorageEvent";
415
+ readonly type: "escrow_manager::components::escrow_storage::escrow_storage::Event";
416
+ readonly kind: "nested";
417
+ }, {
418
+ readonly name: "Initialize";
419
+ readonly type: "escrow_manager::events::Initialize";
420
+ readonly kind: "nested";
421
+ }, {
422
+ readonly name: "Claim";
423
+ readonly type: "escrow_manager::events::Claim";
424
+ readonly kind: "nested";
425
+ }, {
426
+ readonly name: "Refund";
427
+ readonly type: "escrow_manager::events::Refund";
428
+ readonly kind: "nested";
429
+ }];
430
+ }];
431
+ export type EscrowManagerAbiType = typeof EscrowManagerAbi;