@atomiqlabs/chain-evm 1.0.0-dev.89 → 1.0.0-dev.93

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 (185) hide show
  1. package/LICENSE +201 -201
  2. package/dist/chains/botanix/BotanixChainType.d.ts +13 -13
  3. package/dist/chains/botanix/BotanixChainType.js +2 -2
  4. package/dist/chains/botanix/BotanixInitializer.d.ts +30 -30
  5. package/dist/chains/botanix/BotanixInitializer.js +125 -122
  6. package/dist/chains/citrea/CitreaBtcRelay.d.ts +21 -21
  7. package/dist/chains/citrea/CitreaBtcRelay.js +43 -43
  8. package/dist/chains/citrea/CitreaChainType.d.ts +13 -13
  9. package/dist/chains/citrea/CitreaChainType.js +2 -2
  10. package/dist/chains/citrea/CitreaFees.d.ts +29 -29
  11. package/dist/chains/citrea/CitreaFees.js +67 -67
  12. package/dist/chains/citrea/CitreaInitializer.d.ts +30 -30
  13. package/dist/chains/citrea/CitreaInitializer.js +132 -129
  14. package/dist/chains/citrea/CitreaSpvVaultContract.d.ts +15 -15
  15. package/dist/chains/citrea/CitreaSpvVaultContract.js +74 -74
  16. package/dist/chains/citrea/CitreaSwapContract.d.ts +22 -22
  17. package/dist/chains/citrea/CitreaSwapContract.js +96 -96
  18. package/dist/chains/citrea/CitreaTokens.d.ts +9 -9
  19. package/dist/chains/citrea/CitreaTokens.js +20 -20
  20. package/dist/evm/btcrelay/BtcRelayAbi.d.ts +198 -198
  21. package/dist/evm/btcrelay/BtcRelayAbi.js +261 -261
  22. package/dist/evm/btcrelay/BtcRelayTypechain.d.ts +172 -172
  23. package/dist/evm/btcrelay/BtcRelayTypechain.js +2 -2
  24. package/dist/evm/btcrelay/EVMBtcRelay.d.ts +197 -197
  25. package/dist/evm/btcrelay/EVMBtcRelay.js +435 -435
  26. package/dist/evm/btcrelay/headers/EVMBtcHeader.d.ts +33 -33
  27. package/dist/evm/btcrelay/headers/EVMBtcHeader.js +84 -84
  28. package/dist/evm/btcrelay/headers/EVMBtcStoredHeader.d.ts +56 -56
  29. package/dist/evm/btcrelay/headers/EVMBtcStoredHeader.js +123 -123
  30. package/dist/evm/chain/EVMChainInterface.d.ts +54 -51
  31. package/dist/evm/chain/EVMChainInterface.js +89 -89
  32. package/dist/evm/chain/EVMModule.d.ts +9 -9
  33. package/dist/evm/chain/EVMModule.js +13 -13
  34. package/dist/evm/chain/modules/ERC20Abi.d.ts +168 -168
  35. package/dist/evm/chain/modules/ERC20Abi.js +225 -225
  36. package/dist/evm/chain/modules/EVMAddresses.d.ts +10 -10
  37. package/dist/evm/chain/modules/EVMAddresses.js +30 -30
  38. package/dist/evm/chain/modules/EVMBlocks.d.ts +20 -20
  39. package/dist/evm/chain/modules/EVMBlocks.js +64 -64
  40. package/dist/evm/chain/modules/EVMEvents.d.ts +46 -46
  41. package/dist/evm/chain/modules/EVMEvents.js +151 -137
  42. package/dist/evm/chain/modules/EVMFees.d.ts +36 -36
  43. package/dist/evm/chain/modules/EVMFees.js +74 -74
  44. package/dist/evm/chain/modules/EVMSignatures.d.ts +29 -29
  45. package/dist/evm/chain/modules/EVMSignatures.js +68 -68
  46. package/dist/evm/chain/modules/EVMTokens.d.ts +70 -70
  47. package/dist/evm/chain/modules/EVMTokens.js +142 -142
  48. package/dist/evm/chain/modules/EVMTransactions.d.ts +94 -94
  49. package/dist/evm/chain/modules/EVMTransactions.js +288 -286
  50. package/dist/evm/contract/EVMContractBase.d.ts +22 -22
  51. package/dist/evm/contract/EVMContractBase.js +34 -34
  52. package/dist/evm/contract/EVMContractModule.d.ts +8 -8
  53. package/dist/evm/contract/EVMContractModule.js +11 -11
  54. package/dist/evm/contract/modules/EVMContractEvents.d.ts +42 -42
  55. package/dist/evm/contract/modules/EVMContractEvents.js +75 -75
  56. package/dist/evm/events/EVMChainEvents.d.ts +22 -22
  57. package/dist/evm/events/EVMChainEvents.js +69 -69
  58. package/dist/evm/events/EVMChainEventsBrowser.d.ts +102 -102
  59. package/dist/evm/events/EVMChainEventsBrowser.js +412 -412
  60. package/dist/evm/providers/JsonRpcProviderWithRetries.d.ts +16 -16
  61. package/dist/evm/providers/JsonRpcProviderWithRetries.js +27 -27
  62. package/dist/evm/providers/ReconnectingWebSocketProvider.d.ts +22 -22
  63. package/dist/evm/providers/ReconnectingWebSocketProvider.js +91 -91
  64. package/dist/evm/providers/SocketProvider.d.ts +111 -111
  65. package/dist/evm/providers/SocketProvider.js +336 -336
  66. package/dist/evm/providers/WebSocketProviderWithRetries.d.ts +17 -17
  67. package/dist/evm/providers/WebSocketProviderWithRetries.js +23 -23
  68. package/dist/evm/spv_swap/EVMSpvVaultContract.d.ts +107 -79
  69. package/dist/evm/spv_swap/EVMSpvVaultContract.js +578 -482
  70. package/dist/evm/spv_swap/EVMSpvVaultData.d.ts +40 -39
  71. package/dist/evm/spv_swap/EVMSpvVaultData.js +184 -180
  72. package/dist/evm/spv_swap/EVMSpvWithdrawalData.d.ts +19 -19
  73. package/dist/evm/spv_swap/EVMSpvWithdrawalData.js +55 -55
  74. package/dist/evm/spv_swap/SpvVaultContractAbi.d.ts +91 -91
  75. package/dist/evm/spv_swap/SpvVaultContractAbi.js +849 -849
  76. package/dist/evm/spv_swap/SpvVaultContractTypechain.d.ts +450 -450
  77. package/dist/evm/spv_swap/SpvVaultContractTypechain.js +2 -2
  78. package/dist/evm/swaps/EVMSwapContract.d.ts +199 -193
  79. package/dist/evm/swaps/EVMSwapContract.js +394 -378
  80. package/dist/evm/swaps/EVMSwapData.d.ts +66 -66
  81. package/dist/evm/swaps/EVMSwapData.js +260 -260
  82. package/dist/evm/swaps/EVMSwapModule.d.ts +9 -9
  83. package/dist/evm/swaps/EVMSwapModule.js +11 -11
  84. package/dist/evm/swaps/EscrowManagerAbi.d.ts +120 -120
  85. package/dist/evm/swaps/EscrowManagerAbi.js +985 -985
  86. package/dist/evm/swaps/EscrowManagerTypechain.d.ts +475 -475
  87. package/dist/evm/swaps/EscrowManagerTypechain.js +2 -2
  88. package/dist/evm/swaps/handlers/IHandler.d.ts +13 -13
  89. package/dist/evm/swaps/handlers/IHandler.js +2 -2
  90. package/dist/evm/swaps/handlers/claim/ClaimHandlers.d.ts +10 -10
  91. package/dist/evm/swaps/handlers/claim/ClaimHandlers.js +13 -13
  92. package/dist/evm/swaps/handlers/claim/HashlockClaimHandler.d.ts +20 -20
  93. package/dist/evm/swaps/handlers/claim/HashlockClaimHandler.js +39 -39
  94. package/dist/evm/swaps/handlers/claim/btc/BitcoinNoncedOutputClaimHandler.d.ts +24 -24
  95. package/dist/evm/swaps/handlers/claim/btc/BitcoinNoncedOutputClaimHandler.js +59 -59
  96. package/dist/evm/swaps/handlers/claim/btc/BitcoinOutputClaimHandler.d.ts +25 -25
  97. package/dist/evm/swaps/handlers/claim/btc/BitcoinOutputClaimHandler.js +51 -51
  98. package/dist/evm/swaps/handlers/claim/btc/BitcoinTxIdClaimHandler.d.ts +21 -21
  99. package/dist/evm/swaps/handlers/claim/btc/BitcoinTxIdClaimHandler.js +28 -28
  100. package/dist/evm/swaps/handlers/claim/btc/IBitcoinClaimHandler.d.ts +48 -48
  101. package/dist/evm/swaps/handlers/claim/btc/IBitcoinClaimHandler.js +63 -63
  102. package/dist/evm/swaps/handlers/refund/TimelockRefundHandler.d.ts +17 -17
  103. package/dist/evm/swaps/handlers/refund/TimelockRefundHandler.js +28 -28
  104. package/dist/evm/swaps/modules/EVMLpVault.d.ts +69 -69
  105. package/dist/evm/swaps/modules/EVMLpVault.js +134 -134
  106. package/dist/evm/swaps/modules/EVMSwapClaim.d.ts +54 -54
  107. package/dist/evm/swaps/modules/EVMSwapClaim.js +137 -137
  108. package/dist/evm/swaps/modules/EVMSwapInit.d.ts +88 -88
  109. package/dist/evm/swaps/modules/EVMSwapInit.js +274 -274
  110. package/dist/evm/swaps/modules/EVMSwapRefund.d.ts +62 -62
  111. package/dist/evm/swaps/modules/EVMSwapRefund.js +167 -167
  112. package/dist/evm/typechain/common.d.ts +50 -50
  113. package/dist/evm/typechain/common.js +2 -2
  114. package/dist/evm/wallet/EVMBrowserSigner.d.ts +5 -5
  115. package/dist/evm/wallet/EVMBrowserSigner.js +11 -11
  116. package/dist/evm/wallet/EVMPersistentSigner.d.ts +29 -29
  117. package/dist/evm/wallet/EVMPersistentSigner.js +230 -230
  118. package/dist/evm/wallet/EVMSigner.d.ts +11 -11
  119. package/dist/evm/wallet/EVMSigner.js +24 -24
  120. package/dist/index.d.ts +44 -44
  121. package/dist/index.js +60 -60
  122. package/dist/utils/Utils.d.ts +19 -19
  123. package/dist/utils/Utils.js +98 -98
  124. package/package.json +39 -39
  125. package/src/chains/botanix/BotanixChainType.ts +28 -28
  126. package/src/chains/botanix/BotanixInitializer.ts +175 -171
  127. package/src/chains/citrea/CitreaBtcRelay.ts +57 -57
  128. package/src/chains/citrea/CitreaChainType.ts +28 -28
  129. package/src/chains/citrea/CitreaFees.ts +77 -77
  130. package/src/chains/citrea/CitreaInitializer.ts +182 -178
  131. package/src/chains/citrea/CitreaSpvVaultContract.ts +75 -75
  132. package/src/chains/citrea/CitreaSwapContract.ts +102 -102
  133. package/src/chains/citrea/CitreaTokens.ts +21 -21
  134. package/src/evm/btcrelay/BtcRelayAbi.ts +258 -258
  135. package/src/evm/btcrelay/BtcRelayTypechain.ts +371 -371
  136. package/src/evm/btcrelay/EVMBtcRelay.ts +537 -537
  137. package/src/evm/btcrelay/headers/EVMBtcHeader.ts +109 -109
  138. package/src/evm/btcrelay/headers/EVMBtcStoredHeader.ts +152 -152
  139. package/src/evm/chain/EVMChainInterface.ts +158 -155
  140. package/src/evm/chain/EVMModule.ts +21 -21
  141. package/src/evm/chain/modules/ERC20Abi.ts +222 -222
  142. package/src/evm/chain/modules/EVMAddresses.ts +28 -28
  143. package/src/evm/chain/modules/EVMBlocks.ts +75 -75
  144. package/src/evm/chain/modules/EVMEvents.ts +182 -156
  145. package/src/evm/chain/modules/EVMFees.ts +104 -104
  146. package/src/evm/chain/modules/EVMSignatures.ts +76 -76
  147. package/src/evm/chain/modules/EVMTokens.ts +155 -155
  148. package/src/evm/chain/modules/EVMTransactions.ts +327 -325
  149. package/src/evm/contract/EVMContractBase.ts +63 -63
  150. package/src/evm/contract/EVMContractModule.ts +16 -16
  151. package/src/evm/contract/modules/EVMContractEvents.ts +102 -102
  152. package/src/evm/events/EVMChainEvents.ts +82 -82
  153. package/src/evm/events/EVMChainEventsBrowser.ts +533 -533
  154. package/src/evm/providers/JsonRpcProviderWithRetries.ts +33 -33
  155. package/src/evm/providers/ReconnectingWebSocketProvider.ts +106 -106
  156. package/src/evm/providers/SocketProvider.ts +371 -371
  157. package/src/evm/providers/WebSocketProviderWithRetries.ts +34 -34
  158. package/src/evm/spv_swap/EVMSpvVaultContract.ts +723 -615
  159. package/src/evm/spv_swap/EVMSpvVaultData.ts +228 -224
  160. package/src/evm/spv_swap/EVMSpvWithdrawalData.ts +70 -70
  161. package/src/evm/spv_swap/SpvVaultContractAbi.ts +846 -846
  162. package/src/evm/spv_swap/SpvVaultContractTypechain.ts +685 -685
  163. package/src/evm/swaps/EVMSwapContract.ts +621 -600
  164. package/src/evm/swaps/EVMSwapData.ts +378 -378
  165. package/src/evm/swaps/EVMSwapModule.ts +16 -16
  166. package/src/evm/swaps/EscrowManagerAbi.ts +982 -982
  167. package/src/evm/swaps/EscrowManagerTypechain.ts +723 -723
  168. package/src/evm/swaps/handlers/IHandler.ts +17 -17
  169. package/src/evm/swaps/handlers/claim/ClaimHandlers.ts +20 -20
  170. package/src/evm/swaps/handlers/claim/HashlockClaimHandler.ts +46 -46
  171. package/src/evm/swaps/handlers/claim/btc/BitcoinNoncedOutputClaimHandler.ts +82 -82
  172. package/src/evm/swaps/handlers/claim/btc/BitcoinOutputClaimHandler.ts +76 -76
  173. package/src/evm/swaps/handlers/claim/btc/BitcoinTxIdClaimHandler.ts +46 -46
  174. package/src/evm/swaps/handlers/claim/btc/IBitcoinClaimHandler.ts +115 -115
  175. package/src/evm/swaps/handlers/refund/TimelockRefundHandler.ts +37 -37
  176. package/src/evm/swaps/modules/EVMLpVault.ts +154 -154
  177. package/src/evm/swaps/modules/EVMSwapClaim.ts +172 -172
  178. package/src/evm/swaps/modules/EVMSwapInit.ts +328 -328
  179. package/src/evm/swaps/modules/EVMSwapRefund.ts +229 -229
  180. package/src/evm/typechain/common.ts +131 -131
  181. package/src/evm/wallet/EVMBrowserSigner.ts +11 -11
  182. package/src/evm/wallet/EVMPersistentSigner.ts +307 -307
  183. package/src/evm/wallet/EVMSigner.ts +31 -31
  184. package/src/index.ts +53 -53
  185. package/src/utils/Utils.ts +111 -111
@@ -1,685 +1,685 @@
1
- /* Autogenerated file. Do not edit manually. */
2
- /* tslint:disable */
3
- /* eslint-disable */
4
- import type {
5
- BaseContract,
6
- BigNumberish,
7
- BytesLike,
8
- FunctionFragment,
9
- Result,
10
- Interface,
11
- EventFragment,
12
- AddressLike,
13
- ContractRunner,
14
- ContractMethod,
15
- Listener,
16
- } from "ethers";
17
- import type {
18
- TypedContractEvent,
19
- TypedDeferredTopicFilter,
20
- TypedEventLog,
21
- TypedLogDescription,
22
- TypedListener,
23
- TypedContractMethod,
24
- } from "../typechain/common";
25
-
26
- export type SpvVaultParametersStruct = {
27
- btcRelayContract: AddressLike;
28
- token0: AddressLike;
29
- token1: AddressLike;
30
- token0Multiplier: BigNumberish;
31
- token1Multiplier: BigNumberish;
32
- confirmations: BigNumberish;
33
- };
34
-
35
- export type SpvVaultParametersStructOutput = [
36
- btcRelayContract: string,
37
- token0: string,
38
- token1: string,
39
- token0Multiplier: bigint,
40
- token1Multiplier: bigint,
41
- confirmations: bigint
42
- ] & {
43
- btcRelayContract: string;
44
- token0: string;
45
- token1: string;
46
- token0Multiplier: bigint;
47
- token1Multiplier: bigint;
48
- confirmations: bigint;
49
- };
50
-
51
- export type StoredBlockHeaderStruct = {
52
- data: [BytesLike, BytesLike, BytesLike, BytesLike, BytesLike];
53
- };
54
-
55
- export type StoredBlockHeaderStructOutput = [
56
- data: [string, string, string, string, string]
57
- ] & { data: [string, string, string, string, string] };
58
-
59
- export type BitcoinVaultTransactionDataStruct = {
60
- recipient: AddressLike;
61
- amount0: BigNumberish;
62
- amount1: BigNumberish;
63
- callerFee0: BigNumberish;
64
- callerFee1: BigNumberish;
65
- frontingFee0: BigNumberish;
66
- frontingFee1: BigNumberish;
67
- executionHandlerFeeAmount0: BigNumberish;
68
- executionHash: BytesLike;
69
- executionExpiry: BigNumberish;
70
- };
71
-
72
- export type BitcoinVaultTransactionDataStructOutput = [
73
- recipient: string,
74
- amount0: bigint,
75
- amount1: bigint,
76
- callerFee0: bigint,
77
- callerFee1: bigint,
78
- frontingFee0: bigint,
79
- frontingFee1: bigint,
80
- executionHandlerFeeAmount0: bigint,
81
- executionHash: string,
82
- executionExpiry: bigint
83
- ] & {
84
- recipient: string;
85
- amount0: bigint;
86
- amount1: bigint;
87
- callerFee0: bigint;
88
- callerFee1: bigint;
89
- frontingFee0: bigint;
90
- frontingFee1: bigint;
91
- executionHandlerFeeAmount0: bigint;
92
- executionHash: string;
93
- executionExpiry: bigint;
94
- };
95
-
96
- export type SpvVaultStateStruct = {
97
- spvVaultParametersCommitment: BytesLike;
98
- utxoTxHash: BytesLike;
99
- utxoVout: BigNumberish;
100
- openBlockheight: BigNumberish;
101
- withdrawCount: BigNumberish;
102
- depositCount: BigNumberish;
103
- token0Amount: BigNumberish;
104
- token1Amount: BigNumberish;
105
- };
106
-
107
- export type SpvVaultStateStructOutput = [
108
- spvVaultParametersCommitment: string,
109
- utxoTxHash: string,
110
- utxoVout: bigint,
111
- openBlockheight: bigint,
112
- withdrawCount: bigint,
113
- depositCount: bigint,
114
- token0Amount: bigint,
115
- token1Amount: bigint
116
- ] & {
117
- spvVaultParametersCommitment: string;
118
- utxoTxHash: string;
119
- utxoVout: bigint;
120
- openBlockheight: bigint;
121
- withdrawCount: bigint;
122
- depositCount: bigint;
123
- token0Amount: bigint;
124
- token1Amount: bigint;
125
- };
126
-
127
- export interface SpvVaultManagerInterface extends Interface {
128
- getFunction(
129
- nameOrSignature:
130
- | "claim"
131
- | "deposit"
132
- | "front"
133
- | "getFronterAddress"
134
- | "getFronterById"
135
- | "getVault"
136
- | "open"
137
- | "parseBitcoinTx"
138
- ): FunctionFragment;
139
-
140
- getEvent(
141
- nameOrSignatureOrTopic:
142
- | "Claimed"
143
- | "Closed"
144
- | "Deposited"
145
- | "Fronted"
146
- | "Opened"
147
- ): EventFragment;
148
-
149
- encodeFunctionData(
150
- functionFragment: "claim",
151
- values: [
152
- AddressLike,
153
- BigNumberish,
154
- SpvVaultParametersStruct,
155
- BytesLike,
156
- StoredBlockHeaderStruct,
157
- BytesLike[],
158
- BigNumberish
159
- ]
160
- ): string;
161
- encodeFunctionData(
162
- functionFragment: "deposit",
163
- values: [
164
- AddressLike,
165
- BigNumberish,
166
- SpvVaultParametersStruct,
167
- BigNumberish,
168
- BigNumberish
169
- ]
170
- ): string;
171
- encodeFunctionData(
172
- functionFragment: "front",
173
- values: [
174
- AddressLike,
175
- BigNumberish,
176
- SpvVaultParametersStruct,
177
- BigNumberish,
178
- BytesLike,
179
- BitcoinVaultTransactionDataStruct
180
- ]
181
- ): string;
182
- encodeFunctionData(
183
- functionFragment: "getFronterAddress",
184
- values: [
185
- AddressLike,
186
- BigNumberish,
187
- BytesLike,
188
- BitcoinVaultTransactionDataStruct
189
- ]
190
- ): string;
191
- encodeFunctionData(
192
- functionFragment: "getFronterById",
193
- values: [AddressLike, BigNumberish, BytesLike]
194
- ): string;
195
- encodeFunctionData(
196
- functionFragment: "getVault",
197
- values: [AddressLike, BigNumberish]
198
- ): string;
199
- encodeFunctionData(
200
- functionFragment: "open",
201
- values: [BigNumberish, SpvVaultParametersStruct, BytesLike, BigNumberish]
202
- ): string;
203
- encodeFunctionData(
204
- functionFragment: "parseBitcoinTx",
205
- values: [BytesLike]
206
- ): string;
207
-
208
- decodeFunctionResult(functionFragment: "claim", data: BytesLike): Result;
209
- decodeFunctionResult(functionFragment: "deposit", data: BytesLike): Result;
210
- decodeFunctionResult(functionFragment: "front", data: BytesLike): Result;
211
- decodeFunctionResult(
212
- functionFragment: "getFronterAddress",
213
- data: BytesLike
214
- ): Result;
215
- decodeFunctionResult(
216
- functionFragment: "getFronterById",
217
- data: BytesLike
218
- ): Result;
219
- decodeFunctionResult(functionFragment: "getVault", data: BytesLike): Result;
220
- decodeFunctionResult(functionFragment: "open", data: BytesLike): Result;
221
- decodeFunctionResult(
222
- functionFragment: "parseBitcoinTx",
223
- data: BytesLike
224
- ): Result;
225
- }
226
-
227
- export namespace ClaimedEvent {
228
- export type InputTuple = [
229
- ownerAndVaultId: BytesLike,
230
- recipient: AddressLike,
231
- btcTxHash: BytesLike,
232
- caller: AddressLike,
233
- executionHash: BytesLike,
234
- frontingAddress: AddressLike,
235
- withdrawCount: BigNumberish,
236
- amount0: BigNumberish,
237
- amount1: BigNumberish
238
- ];
239
- export type OutputTuple = [
240
- ownerAndVaultId: string,
241
- recipient: string,
242
- btcTxHash: string,
243
- caller: string,
244
- executionHash: string,
245
- frontingAddress: string,
246
- withdrawCount: bigint,
247
- amount0: bigint,
248
- amount1: bigint
249
- ];
250
- export interface OutputObject {
251
- ownerAndVaultId: string;
252
- recipient: string;
253
- btcTxHash: string;
254
- caller: string;
255
- executionHash: string;
256
- frontingAddress: string;
257
- withdrawCount: bigint;
258
- amount0: bigint;
259
- amount1: bigint;
260
- }
261
- export type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
262
- export type Filter = TypedDeferredTopicFilter<Event>;
263
- export type Log = TypedEventLog<Event>;
264
- export type LogDescription = TypedLogDescription<Event>;
265
- }
266
-
267
- export namespace ClosedEvent {
268
- export type InputTuple = [
269
- owner: AddressLike,
270
- vaultId: BigNumberish,
271
- btcTxHash: BytesLike,
272
- error: BytesLike
273
- ];
274
- export type OutputTuple = [
275
- owner: string,
276
- vaultId: bigint,
277
- btcTxHash: string,
278
- error: string
279
- ];
280
- export interface OutputObject {
281
- owner: string;
282
- vaultId: bigint;
283
- btcTxHash: string;
284
- error: string;
285
- }
286
- export type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
287
- export type Filter = TypedDeferredTopicFilter<Event>;
288
- export type Log = TypedEventLog<Event>;
289
- export type LogDescription = TypedLogDescription<Event>;
290
- }
291
-
292
- export namespace DepositedEvent {
293
- export type InputTuple = [
294
- ownerAndVaultId: BytesLike,
295
- depositCount: BigNumberish,
296
- amount0: BigNumberish,
297
- amount1: BigNumberish
298
- ];
299
- export type OutputTuple = [
300
- ownerAndVaultId: string,
301
- depositCount: bigint,
302
- amount0: bigint,
303
- amount1: bigint
304
- ];
305
- export interface OutputObject {
306
- ownerAndVaultId: string;
307
- depositCount: bigint;
308
- amount0: bigint;
309
- amount1: bigint;
310
- }
311
- export type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
312
- export type Filter = TypedDeferredTopicFilter<Event>;
313
- export type Log = TypedEventLog<Event>;
314
- export type LogDescription = TypedLogDescription<Event>;
315
- }
316
-
317
- export namespace FrontedEvent {
318
- export type InputTuple = [
319
- ownerAndVaultId: BytesLike,
320
- recipient: AddressLike,
321
- btcTxHash: BytesLike,
322
- caller: AddressLike,
323
- executionHash: BytesLike,
324
- amount0: BigNumberish,
325
- amount1: BigNumberish
326
- ];
327
- export type OutputTuple = [
328
- ownerAndVaultId: string,
329
- recipient: string,
330
- btcTxHash: string,
331
- caller: string,
332
- executionHash: string,
333
- amount0: bigint,
334
- amount1: bigint
335
- ];
336
- export interface OutputObject {
337
- ownerAndVaultId: string;
338
- recipient: string;
339
- btcTxHash: string;
340
- caller: string;
341
- executionHash: string;
342
- amount0: bigint;
343
- amount1: bigint;
344
- }
345
- export type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
346
- export type Filter = TypedDeferredTopicFilter<Event>;
347
- export type Log = TypedEventLog<Event>;
348
- export type LogDescription = TypedLogDescription<Event>;
349
- }
350
-
351
- export namespace OpenedEvent {
352
- export type InputTuple = [
353
- owner: AddressLike,
354
- vaultId: BigNumberish,
355
- btcTxHash: BytesLike,
356
- vout: BigNumberish,
357
- params: SpvVaultParametersStruct
358
- ];
359
- export type OutputTuple = [
360
- owner: string,
361
- vaultId: bigint,
362
- btcTxHash: string,
363
- vout: bigint,
364
- params: SpvVaultParametersStructOutput
365
- ];
366
- export interface OutputObject {
367
- owner: string;
368
- vaultId: bigint;
369
- btcTxHash: string;
370
- vout: bigint;
371
- params: SpvVaultParametersStructOutput;
372
- }
373
- export type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
374
- export type Filter = TypedDeferredTopicFilter<Event>;
375
- export type Log = TypedEventLog<Event>;
376
- export type LogDescription = TypedLogDescription<Event>;
377
- }
378
-
379
- export interface SpvVaultManager extends BaseContract {
380
- connect(runner?: ContractRunner | null): SpvVaultManager;
381
- waitForDeployment(): Promise<this>;
382
-
383
- interface: SpvVaultManagerInterface;
384
-
385
- queryFilter<TCEvent extends TypedContractEvent>(
386
- event: TCEvent,
387
- fromBlockOrBlockhash?: string | number | undefined,
388
- toBlock?: string | number | undefined
389
- ): Promise<Array<TypedEventLog<TCEvent>>>;
390
- queryFilter<TCEvent extends TypedContractEvent>(
391
- filter: TypedDeferredTopicFilter<TCEvent>,
392
- fromBlockOrBlockhash?: string | number | undefined,
393
- toBlock?: string | number | undefined
394
- ): Promise<Array<TypedEventLog<TCEvent>>>;
395
-
396
- on<TCEvent extends TypedContractEvent>(
397
- event: TCEvent,
398
- listener: TypedListener<TCEvent>
399
- ): Promise<this>;
400
- on<TCEvent extends TypedContractEvent>(
401
- filter: TypedDeferredTopicFilter<TCEvent>,
402
- listener: TypedListener<TCEvent>
403
- ): Promise<this>;
404
-
405
- once<TCEvent extends TypedContractEvent>(
406
- event: TCEvent,
407
- listener: TypedListener<TCEvent>
408
- ): Promise<this>;
409
- once<TCEvent extends TypedContractEvent>(
410
- filter: TypedDeferredTopicFilter<TCEvent>,
411
- listener: TypedListener<TCEvent>
412
- ): Promise<this>;
413
-
414
- listeners<TCEvent extends TypedContractEvent>(
415
- event: TCEvent
416
- ): Promise<Array<TypedListener<TCEvent>>>;
417
- listeners(eventName?: string): Promise<Array<Listener>>;
418
- removeAllListeners<TCEvent extends TypedContractEvent>(
419
- event?: TCEvent
420
- ): Promise<this>;
421
-
422
- claim: TypedContractMethod<
423
- [
424
- owner: AddressLike,
425
- vaultId: BigNumberish,
426
- vaultParams: SpvVaultParametersStruct,
427
- transaction: BytesLike,
428
- blockheader: StoredBlockHeaderStruct,
429
- merkleProof: BytesLike[],
430
- position: BigNumberish
431
- ],
432
- [void],
433
- "nonpayable"
434
- >;
435
-
436
- deposit: TypedContractMethod<
437
- [
438
- owner: AddressLike,
439
- vaultId: BigNumberish,
440
- vaultParams: SpvVaultParametersStruct,
441
- rawToken0: BigNumberish,
442
- rawToken1: BigNumberish
443
- ],
444
- [void],
445
- "payable"
446
- >;
447
-
448
- front: TypedContractMethod<
449
- [
450
- owner: AddressLike,
451
- vaultId: BigNumberish,
452
- vaultParams: SpvVaultParametersStruct,
453
- withdrawalSequence: BigNumberish,
454
- btcTxHash: BytesLike,
455
- data: BitcoinVaultTransactionDataStruct
456
- ],
457
- [void],
458
- "payable"
459
- >;
460
-
461
- getFronterAddress: TypedContractMethod<
462
- [
463
- owner: AddressLike,
464
- vaultId: BigNumberish,
465
- btcTxHash: BytesLike,
466
- data: BitcoinVaultTransactionDataStruct
467
- ],
468
- [string],
469
- "view"
470
- >;
471
-
472
- getFronterById: TypedContractMethod<
473
- [owner: AddressLike, vaultId: BigNumberish, frontingId: BytesLike],
474
- [string],
475
- "view"
476
- >;
477
-
478
- getVault: TypedContractMethod<
479
- [owner: AddressLike, vaultId: BigNumberish],
480
- [SpvVaultStateStructOutput],
481
- "view"
482
- >;
483
-
484
- open: TypedContractMethod<
485
- [
486
- vaultId: BigNumberish,
487
- vaultParams: SpvVaultParametersStruct,
488
- utxoTxHash: BytesLike,
489
- utxoVout: BigNumberish
490
- ],
491
- [void],
492
- "nonpayable"
493
- >;
494
-
495
- parseBitcoinTx: TypedContractMethod<
496
- [transaction: BytesLike],
497
- [BitcoinVaultTransactionDataStructOutput],
498
- "view"
499
- >;
500
-
501
- getFunction<T extends ContractMethod = ContractMethod>(
502
- key: string | FunctionFragment
503
- ): T;
504
-
505
- getFunction(
506
- nameOrSignature: "claim"
507
- ): TypedContractMethod<
508
- [
509
- owner: AddressLike,
510
- vaultId: BigNumberish,
511
- vaultParams: SpvVaultParametersStruct,
512
- transaction: BytesLike,
513
- blockheader: StoredBlockHeaderStruct,
514
- merkleProof: BytesLike[],
515
- position: BigNumberish
516
- ],
517
- [void],
518
- "nonpayable"
519
- >;
520
- getFunction(
521
- nameOrSignature: "deposit"
522
- ): TypedContractMethod<
523
- [
524
- owner: AddressLike,
525
- vaultId: BigNumberish,
526
- vaultParams: SpvVaultParametersStruct,
527
- rawToken0: BigNumberish,
528
- rawToken1: BigNumberish
529
- ],
530
- [void],
531
- "payable"
532
- >;
533
- getFunction(
534
- nameOrSignature: "front"
535
- ): TypedContractMethod<
536
- [
537
- owner: AddressLike,
538
- vaultId: BigNumberish,
539
- vaultParams: SpvVaultParametersStruct,
540
- withdrawalSequence: BigNumberish,
541
- btcTxHash: BytesLike,
542
- data: BitcoinVaultTransactionDataStruct
543
- ],
544
- [void],
545
- "payable"
546
- >;
547
- getFunction(
548
- nameOrSignature: "getFronterAddress"
549
- ): TypedContractMethod<
550
- [
551
- owner: AddressLike,
552
- vaultId: BigNumberish,
553
- btcTxHash: BytesLike,
554
- data: BitcoinVaultTransactionDataStruct
555
- ],
556
- [string],
557
- "view"
558
- >;
559
- getFunction(
560
- nameOrSignature: "getFronterById"
561
- ): TypedContractMethod<
562
- [owner: AddressLike, vaultId: BigNumberish, frontingId: BytesLike],
563
- [string],
564
- "view"
565
- >;
566
- getFunction(
567
- nameOrSignature: "getVault"
568
- ): TypedContractMethod<
569
- [owner: AddressLike, vaultId: BigNumberish],
570
- [SpvVaultStateStructOutput],
571
- "view"
572
- >;
573
- getFunction(
574
- nameOrSignature: "open"
575
- ): TypedContractMethod<
576
- [
577
- vaultId: BigNumberish,
578
- vaultParams: SpvVaultParametersStruct,
579
- utxoTxHash: BytesLike,
580
- utxoVout: BigNumberish
581
- ],
582
- [void],
583
- "nonpayable"
584
- >;
585
- getFunction(
586
- nameOrSignature: "parseBitcoinTx"
587
- ): TypedContractMethod<
588
- [transaction: BytesLike],
589
- [BitcoinVaultTransactionDataStructOutput],
590
- "view"
591
- >;
592
-
593
- getEvent(
594
- key: "Claimed"
595
- ): TypedContractEvent<
596
- ClaimedEvent.InputTuple,
597
- ClaimedEvent.OutputTuple,
598
- ClaimedEvent.OutputObject
599
- >;
600
- getEvent(
601
- key: "Closed"
602
- ): TypedContractEvent<
603
- ClosedEvent.InputTuple,
604
- ClosedEvent.OutputTuple,
605
- ClosedEvent.OutputObject
606
- >;
607
- getEvent(
608
- key: "Deposited"
609
- ): TypedContractEvent<
610
- DepositedEvent.InputTuple,
611
- DepositedEvent.OutputTuple,
612
- DepositedEvent.OutputObject
613
- >;
614
- getEvent(
615
- key: "Fronted"
616
- ): TypedContractEvent<
617
- FrontedEvent.InputTuple,
618
- FrontedEvent.OutputTuple,
619
- FrontedEvent.OutputObject
620
- >;
621
- getEvent(
622
- key: "Opened"
623
- ): TypedContractEvent<
624
- OpenedEvent.InputTuple,
625
- OpenedEvent.OutputTuple,
626
- OpenedEvent.OutputObject
627
- >;
628
-
629
- filters: {
630
- "Claimed(bytes32,address,bytes32,address,bytes32,address,uint32,uint64,uint64)": TypedContractEvent<
631
- ClaimedEvent.InputTuple,
632
- ClaimedEvent.OutputTuple,
633
- ClaimedEvent.OutputObject
634
- >;
635
- Claimed: TypedContractEvent<
636
- ClaimedEvent.InputTuple,
637
- ClaimedEvent.OutputTuple,
638
- ClaimedEvent.OutputObject
639
- >;
640
-
641
- "Closed(address,uint96,bytes32,bytes)": TypedContractEvent<
642
- ClosedEvent.InputTuple,
643
- ClosedEvent.OutputTuple,
644
- ClosedEvent.OutputObject
645
- >;
646
- Closed: TypedContractEvent<
647
- ClosedEvent.InputTuple,
648
- ClosedEvent.OutputTuple,
649
- ClosedEvent.OutputObject
650
- >;
651
-
652
- "Deposited(bytes32,uint32,uint64,uint64)": TypedContractEvent<
653
- DepositedEvent.InputTuple,
654
- DepositedEvent.OutputTuple,
655
- DepositedEvent.OutputObject
656
- >;
657
- Deposited: TypedContractEvent<
658
- DepositedEvent.InputTuple,
659
- DepositedEvent.OutputTuple,
660
- DepositedEvent.OutputObject
661
- >;
662
-
663
- "Fronted(bytes32,address,bytes32,address,bytes32,uint64,uint64)": TypedContractEvent<
664
- FrontedEvent.InputTuple,
665
- FrontedEvent.OutputTuple,
666
- FrontedEvent.OutputObject
667
- >;
668
- Fronted: TypedContractEvent<
669
- FrontedEvent.InputTuple,
670
- FrontedEvent.OutputTuple,
671
- FrontedEvent.OutputObject
672
- >;
673
-
674
- "Opened(address,uint96,bytes32,uint32,tuple)": TypedContractEvent<
675
- OpenedEvent.InputTuple,
676
- OpenedEvent.OutputTuple,
677
- OpenedEvent.OutputObject
678
- >;
679
- Opened: TypedContractEvent<
680
- OpenedEvent.InputTuple,
681
- OpenedEvent.OutputTuple,
682
- OpenedEvent.OutputObject
683
- >;
684
- };
685
- }
1
+ /* Autogenerated file. Do not edit manually. */
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ import type {
5
+ BaseContract,
6
+ BigNumberish,
7
+ BytesLike,
8
+ FunctionFragment,
9
+ Result,
10
+ Interface,
11
+ EventFragment,
12
+ AddressLike,
13
+ ContractRunner,
14
+ ContractMethod,
15
+ Listener,
16
+ } from "ethers";
17
+ import type {
18
+ TypedContractEvent,
19
+ TypedDeferredTopicFilter,
20
+ TypedEventLog,
21
+ TypedLogDescription,
22
+ TypedListener,
23
+ TypedContractMethod,
24
+ } from "../typechain/common";
25
+
26
+ export type SpvVaultParametersStruct = {
27
+ btcRelayContract: AddressLike;
28
+ token0: AddressLike;
29
+ token1: AddressLike;
30
+ token0Multiplier: BigNumberish;
31
+ token1Multiplier: BigNumberish;
32
+ confirmations: BigNumberish;
33
+ };
34
+
35
+ export type SpvVaultParametersStructOutput = [
36
+ btcRelayContract: string,
37
+ token0: string,
38
+ token1: string,
39
+ token0Multiplier: bigint,
40
+ token1Multiplier: bigint,
41
+ confirmations: bigint
42
+ ] & {
43
+ btcRelayContract: string;
44
+ token0: string;
45
+ token1: string;
46
+ token0Multiplier: bigint;
47
+ token1Multiplier: bigint;
48
+ confirmations: bigint;
49
+ };
50
+
51
+ export type StoredBlockHeaderStruct = {
52
+ data: [BytesLike, BytesLike, BytesLike, BytesLike, BytesLike];
53
+ };
54
+
55
+ export type StoredBlockHeaderStructOutput = [
56
+ data: [string, string, string, string, string]
57
+ ] & { data: [string, string, string, string, string] };
58
+
59
+ export type BitcoinVaultTransactionDataStruct = {
60
+ recipient: AddressLike;
61
+ amount0: BigNumberish;
62
+ amount1: BigNumberish;
63
+ callerFee0: BigNumberish;
64
+ callerFee1: BigNumberish;
65
+ frontingFee0: BigNumberish;
66
+ frontingFee1: BigNumberish;
67
+ executionHandlerFeeAmount0: BigNumberish;
68
+ executionHash: BytesLike;
69
+ executionExpiry: BigNumberish;
70
+ };
71
+
72
+ export type BitcoinVaultTransactionDataStructOutput = [
73
+ recipient: string,
74
+ amount0: bigint,
75
+ amount1: bigint,
76
+ callerFee0: bigint,
77
+ callerFee1: bigint,
78
+ frontingFee0: bigint,
79
+ frontingFee1: bigint,
80
+ executionHandlerFeeAmount0: bigint,
81
+ executionHash: string,
82
+ executionExpiry: bigint
83
+ ] & {
84
+ recipient: string;
85
+ amount0: bigint;
86
+ amount1: bigint;
87
+ callerFee0: bigint;
88
+ callerFee1: bigint;
89
+ frontingFee0: bigint;
90
+ frontingFee1: bigint;
91
+ executionHandlerFeeAmount0: bigint;
92
+ executionHash: string;
93
+ executionExpiry: bigint;
94
+ };
95
+
96
+ export type SpvVaultStateStruct = {
97
+ spvVaultParametersCommitment: BytesLike;
98
+ utxoTxHash: BytesLike;
99
+ utxoVout: BigNumberish;
100
+ openBlockheight: BigNumberish;
101
+ withdrawCount: BigNumberish;
102
+ depositCount: BigNumberish;
103
+ token0Amount: BigNumberish;
104
+ token1Amount: BigNumberish;
105
+ };
106
+
107
+ export type SpvVaultStateStructOutput = [
108
+ spvVaultParametersCommitment: string,
109
+ utxoTxHash: string,
110
+ utxoVout: bigint,
111
+ openBlockheight: bigint,
112
+ withdrawCount: bigint,
113
+ depositCount: bigint,
114
+ token0Amount: bigint,
115
+ token1Amount: bigint
116
+ ] & {
117
+ spvVaultParametersCommitment: string;
118
+ utxoTxHash: string;
119
+ utxoVout: bigint;
120
+ openBlockheight: bigint;
121
+ withdrawCount: bigint;
122
+ depositCount: bigint;
123
+ token0Amount: bigint;
124
+ token1Amount: bigint;
125
+ };
126
+
127
+ export interface SpvVaultManagerInterface extends Interface {
128
+ getFunction(
129
+ nameOrSignature:
130
+ | "claim"
131
+ | "deposit"
132
+ | "front"
133
+ | "getFronterAddress"
134
+ | "getFronterById"
135
+ | "getVault"
136
+ | "open"
137
+ | "parseBitcoinTx"
138
+ ): FunctionFragment;
139
+
140
+ getEvent(
141
+ nameOrSignatureOrTopic:
142
+ | "Claimed"
143
+ | "Closed"
144
+ | "Deposited"
145
+ | "Fronted"
146
+ | "Opened"
147
+ ): EventFragment;
148
+
149
+ encodeFunctionData(
150
+ functionFragment: "claim",
151
+ values: [
152
+ AddressLike,
153
+ BigNumberish,
154
+ SpvVaultParametersStruct,
155
+ BytesLike,
156
+ StoredBlockHeaderStruct,
157
+ BytesLike[],
158
+ BigNumberish
159
+ ]
160
+ ): string;
161
+ encodeFunctionData(
162
+ functionFragment: "deposit",
163
+ values: [
164
+ AddressLike,
165
+ BigNumberish,
166
+ SpvVaultParametersStruct,
167
+ BigNumberish,
168
+ BigNumberish
169
+ ]
170
+ ): string;
171
+ encodeFunctionData(
172
+ functionFragment: "front",
173
+ values: [
174
+ AddressLike,
175
+ BigNumberish,
176
+ SpvVaultParametersStruct,
177
+ BigNumberish,
178
+ BytesLike,
179
+ BitcoinVaultTransactionDataStruct
180
+ ]
181
+ ): string;
182
+ encodeFunctionData(
183
+ functionFragment: "getFronterAddress",
184
+ values: [
185
+ AddressLike,
186
+ BigNumberish,
187
+ BytesLike,
188
+ BitcoinVaultTransactionDataStruct
189
+ ]
190
+ ): string;
191
+ encodeFunctionData(
192
+ functionFragment: "getFronterById",
193
+ values: [AddressLike, BigNumberish, BytesLike]
194
+ ): string;
195
+ encodeFunctionData(
196
+ functionFragment: "getVault",
197
+ values: [AddressLike, BigNumberish]
198
+ ): string;
199
+ encodeFunctionData(
200
+ functionFragment: "open",
201
+ values: [BigNumberish, SpvVaultParametersStruct, BytesLike, BigNumberish]
202
+ ): string;
203
+ encodeFunctionData(
204
+ functionFragment: "parseBitcoinTx",
205
+ values: [BytesLike]
206
+ ): string;
207
+
208
+ decodeFunctionResult(functionFragment: "claim", data: BytesLike): Result;
209
+ decodeFunctionResult(functionFragment: "deposit", data: BytesLike): Result;
210
+ decodeFunctionResult(functionFragment: "front", data: BytesLike): Result;
211
+ decodeFunctionResult(
212
+ functionFragment: "getFronterAddress",
213
+ data: BytesLike
214
+ ): Result;
215
+ decodeFunctionResult(
216
+ functionFragment: "getFronterById",
217
+ data: BytesLike
218
+ ): Result;
219
+ decodeFunctionResult(functionFragment: "getVault", data: BytesLike): Result;
220
+ decodeFunctionResult(functionFragment: "open", data: BytesLike): Result;
221
+ decodeFunctionResult(
222
+ functionFragment: "parseBitcoinTx",
223
+ data: BytesLike
224
+ ): Result;
225
+ }
226
+
227
+ export namespace ClaimedEvent {
228
+ export type InputTuple = [
229
+ ownerAndVaultId: BytesLike,
230
+ recipient: AddressLike,
231
+ btcTxHash: BytesLike,
232
+ caller: AddressLike,
233
+ executionHash: BytesLike,
234
+ frontingAddress: AddressLike,
235
+ withdrawCount: BigNumberish,
236
+ amount0: BigNumberish,
237
+ amount1: BigNumberish
238
+ ];
239
+ export type OutputTuple = [
240
+ ownerAndVaultId: string,
241
+ recipient: string,
242
+ btcTxHash: string,
243
+ caller: string,
244
+ executionHash: string,
245
+ frontingAddress: string,
246
+ withdrawCount: bigint,
247
+ amount0: bigint,
248
+ amount1: bigint
249
+ ];
250
+ export interface OutputObject {
251
+ ownerAndVaultId: string;
252
+ recipient: string;
253
+ btcTxHash: string;
254
+ caller: string;
255
+ executionHash: string;
256
+ frontingAddress: string;
257
+ withdrawCount: bigint;
258
+ amount0: bigint;
259
+ amount1: bigint;
260
+ }
261
+ export type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
262
+ export type Filter = TypedDeferredTopicFilter<Event>;
263
+ export type Log = TypedEventLog<Event>;
264
+ export type LogDescription = TypedLogDescription<Event>;
265
+ }
266
+
267
+ export namespace ClosedEvent {
268
+ export type InputTuple = [
269
+ owner: AddressLike,
270
+ vaultId: BigNumberish,
271
+ btcTxHash: BytesLike,
272
+ error: BytesLike
273
+ ];
274
+ export type OutputTuple = [
275
+ owner: string,
276
+ vaultId: bigint,
277
+ btcTxHash: string,
278
+ error: string
279
+ ];
280
+ export interface OutputObject {
281
+ owner: string;
282
+ vaultId: bigint;
283
+ btcTxHash: string;
284
+ error: string;
285
+ }
286
+ export type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
287
+ export type Filter = TypedDeferredTopicFilter<Event>;
288
+ export type Log = TypedEventLog<Event>;
289
+ export type LogDescription = TypedLogDescription<Event>;
290
+ }
291
+
292
+ export namespace DepositedEvent {
293
+ export type InputTuple = [
294
+ ownerAndVaultId: BytesLike,
295
+ depositCount: BigNumberish,
296
+ amount0: BigNumberish,
297
+ amount1: BigNumberish
298
+ ];
299
+ export type OutputTuple = [
300
+ ownerAndVaultId: string,
301
+ depositCount: bigint,
302
+ amount0: bigint,
303
+ amount1: bigint
304
+ ];
305
+ export interface OutputObject {
306
+ ownerAndVaultId: string;
307
+ depositCount: bigint;
308
+ amount0: bigint;
309
+ amount1: bigint;
310
+ }
311
+ export type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
312
+ export type Filter = TypedDeferredTopicFilter<Event>;
313
+ export type Log = TypedEventLog<Event>;
314
+ export type LogDescription = TypedLogDescription<Event>;
315
+ }
316
+
317
+ export namespace FrontedEvent {
318
+ export type InputTuple = [
319
+ ownerAndVaultId: BytesLike,
320
+ recipient: AddressLike,
321
+ btcTxHash: BytesLike,
322
+ caller: AddressLike,
323
+ executionHash: BytesLike,
324
+ amount0: BigNumberish,
325
+ amount1: BigNumberish
326
+ ];
327
+ export type OutputTuple = [
328
+ ownerAndVaultId: string,
329
+ recipient: string,
330
+ btcTxHash: string,
331
+ caller: string,
332
+ executionHash: string,
333
+ amount0: bigint,
334
+ amount1: bigint
335
+ ];
336
+ export interface OutputObject {
337
+ ownerAndVaultId: string;
338
+ recipient: string;
339
+ btcTxHash: string;
340
+ caller: string;
341
+ executionHash: string;
342
+ amount0: bigint;
343
+ amount1: bigint;
344
+ }
345
+ export type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
346
+ export type Filter = TypedDeferredTopicFilter<Event>;
347
+ export type Log = TypedEventLog<Event>;
348
+ export type LogDescription = TypedLogDescription<Event>;
349
+ }
350
+
351
+ export namespace OpenedEvent {
352
+ export type InputTuple = [
353
+ owner: AddressLike,
354
+ vaultId: BigNumberish,
355
+ btcTxHash: BytesLike,
356
+ vout: BigNumberish,
357
+ params: SpvVaultParametersStruct
358
+ ];
359
+ export type OutputTuple = [
360
+ owner: string,
361
+ vaultId: bigint,
362
+ btcTxHash: string,
363
+ vout: bigint,
364
+ params: SpvVaultParametersStructOutput
365
+ ];
366
+ export interface OutputObject {
367
+ owner: string;
368
+ vaultId: bigint;
369
+ btcTxHash: string;
370
+ vout: bigint;
371
+ params: SpvVaultParametersStructOutput;
372
+ }
373
+ export type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
374
+ export type Filter = TypedDeferredTopicFilter<Event>;
375
+ export type Log = TypedEventLog<Event>;
376
+ export type LogDescription = TypedLogDescription<Event>;
377
+ }
378
+
379
+ export interface SpvVaultManager extends BaseContract {
380
+ connect(runner?: ContractRunner | null): SpvVaultManager;
381
+ waitForDeployment(): Promise<this>;
382
+
383
+ interface: SpvVaultManagerInterface;
384
+
385
+ queryFilter<TCEvent extends TypedContractEvent>(
386
+ event: TCEvent,
387
+ fromBlockOrBlockhash?: string | number | undefined,
388
+ toBlock?: string | number | undefined
389
+ ): Promise<Array<TypedEventLog<TCEvent>>>;
390
+ queryFilter<TCEvent extends TypedContractEvent>(
391
+ filter: TypedDeferredTopicFilter<TCEvent>,
392
+ fromBlockOrBlockhash?: string | number | undefined,
393
+ toBlock?: string | number | undefined
394
+ ): Promise<Array<TypedEventLog<TCEvent>>>;
395
+
396
+ on<TCEvent extends TypedContractEvent>(
397
+ event: TCEvent,
398
+ listener: TypedListener<TCEvent>
399
+ ): Promise<this>;
400
+ on<TCEvent extends TypedContractEvent>(
401
+ filter: TypedDeferredTopicFilter<TCEvent>,
402
+ listener: TypedListener<TCEvent>
403
+ ): Promise<this>;
404
+
405
+ once<TCEvent extends TypedContractEvent>(
406
+ event: TCEvent,
407
+ listener: TypedListener<TCEvent>
408
+ ): Promise<this>;
409
+ once<TCEvent extends TypedContractEvent>(
410
+ filter: TypedDeferredTopicFilter<TCEvent>,
411
+ listener: TypedListener<TCEvent>
412
+ ): Promise<this>;
413
+
414
+ listeners<TCEvent extends TypedContractEvent>(
415
+ event: TCEvent
416
+ ): Promise<Array<TypedListener<TCEvent>>>;
417
+ listeners(eventName?: string): Promise<Array<Listener>>;
418
+ removeAllListeners<TCEvent extends TypedContractEvent>(
419
+ event?: TCEvent
420
+ ): Promise<this>;
421
+
422
+ claim: TypedContractMethod<
423
+ [
424
+ owner: AddressLike,
425
+ vaultId: BigNumberish,
426
+ vaultParams: SpvVaultParametersStruct,
427
+ transaction: BytesLike,
428
+ blockheader: StoredBlockHeaderStruct,
429
+ merkleProof: BytesLike[],
430
+ position: BigNumberish
431
+ ],
432
+ [void],
433
+ "nonpayable"
434
+ >;
435
+
436
+ deposit: TypedContractMethod<
437
+ [
438
+ owner: AddressLike,
439
+ vaultId: BigNumberish,
440
+ vaultParams: SpvVaultParametersStruct,
441
+ rawToken0: BigNumberish,
442
+ rawToken1: BigNumberish
443
+ ],
444
+ [void],
445
+ "payable"
446
+ >;
447
+
448
+ front: TypedContractMethod<
449
+ [
450
+ owner: AddressLike,
451
+ vaultId: BigNumberish,
452
+ vaultParams: SpvVaultParametersStruct,
453
+ withdrawalSequence: BigNumberish,
454
+ btcTxHash: BytesLike,
455
+ data: BitcoinVaultTransactionDataStruct
456
+ ],
457
+ [void],
458
+ "payable"
459
+ >;
460
+
461
+ getFronterAddress: TypedContractMethod<
462
+ [
463
+ owner: AddressLike,
464
+ vaultId: BigNumberish,
465
+ btcTxHash: BytesLike,
466
+ data: BitcoinVaultTransactionDataStruct
467
+ ],
468
+ [string],
469
+ "view"
470
+ >;
471
+
472
+ getFronterById: TypedContractMethod<
473
+ [owner: AddressLike, vaultId: BigNumberish, frontingId: BytesLike],
474
+ [string],
475
+ "view"
476
+ >;
477
+
478
+ getVault: TypedContractMethod<
479
+ [owner: AddressLike, vaultId: BigNumberish],
480
+ [SpvVaultStateStructOutput],
481
+ "view"
482
+ >;
483
+
484
+ open: TypedContractMethod<
485
+ [
486
+ vaultId: BigNumberish,
487
+ vaultParams: SpvVaultParametersStruct,
488
+ utxoTxHash: BytesLike,
489
+ utxoVout: BigNumberish
490
+ ],
491
+ [void],
492
+ "nonpayable"
493
+ >;
494
+
495
+ parseBitcoinTx: TypedContractMethod<
496
+ [transaction: BytesLike],
497
+ [BitcoinVaultTransactionDataStructOutput],
498
+ "view"
499
+ >;
500
+
501
+ getFunction<T extends ContractMethod = ContractMethod>(
502
+ key: string | FunctionFragment
503
+ ): T;
504
+
505
+ getFunction(
506
+ nameOrSignature: "claim"
507
+ ): TypedContractMethod<
508
+ [
509
+ owner: AddressLike,
510
+ vaultId: BigNumberish,
511
+ vaultParams: SpvVaultParametersStruct,
512
+ transaction: BytesLike,
513
+ blockheader: StoredBlockHeaderStruct,
514
+ merkleProof: BytesLike[],
515
+ position: BigNumberish
516
+ ],
517
+ [void],
518
+ "nonpayable"
519
+ >;
520
+ getFunction(
521
+ nameOrSignature: "deposit"
522
+ ): TypedContractMethod<
523
+ [
524
+ owner: AddressLike,
525
+ vaultId: BigNumberish,
526
+ vaultParams: SpvVaultParametersStruct,
527
+ rawToken0: BigNumberish,
528
+ rawToken1: BigNumberish
529
+ ],
530
+ [void],
531
+ "payable"
532
+ >;
533
+ getFunction(
534
+ nameOrSignature: "front"
535
+ ): TypedContractMethod<
536
+ [
537
+ owner: AddressLike,
538
+ vaultId: BigNumberish,
539
+ vaultParams: SpvVaultParametersStruct,
540
+ withdrawalSequence: BigNumberish,
541
+ btcTxHash: BytesLike,
542
+ data: BitcoinVaultTransactionDataStruct
543
+ ],
544
+ [void],
545
+ "payable"
546
+ >;
547
+ getFunction(
548
+ nameOrSignature: "getFronterAddress"
549
+ ): TypedContractMethod<
550
+ [
551
+ owner: AddressLike,
552
+ vaultId: BigNumberish,
553
+ btcTxHash: BytesLike,
554
+ data: BitcoinVaultTransactionDataStruct
555
+ ],
556
+ [string],
557
+ "view"
558
+ >;
559
+ getFunction(
560
+ nameOrSignature: "getFronterById"
561
+ ): TypedContractMethod<
562
+ [owner: AddressLike, vaultId: BigNumberish, frontingId: BytesLike],
563
+ [string],
564
+ "view"
565
+ >;
566
+ getFunction(
567
+ nameOrSignature: "getVault"
568
+ ): TypedContractMethod<
569
+ [owner: AddressLike, vaultId: BigNumberish],
570
+ [SpvVaultStateStructOutput],
571
+ "view"
572
+ >;
573
+ getFunction(
574
+ nameOrSignature: "open"
575
+ ): TypedContractMethod<
576
+ [
577
+ vaultId: BigNumberish,
578
+ vaultParams: SpvVaultParametersStruct,
579
+ utxoTxHash: BytesLike,
580
+ utxoVout: BigNumberish
581
+ ],
582
+ [void],
583
+ "nonpayable"
584
+ >;
585
+ getFunction(
586
+ nameOrSignature: "parseBitcoinTx"
587
+ ): TypedContractMethod<
588
+ [transaction: BytesLike],
589
+ [BitcoinVaultTransactionDataStructOutput],
590
+ "view"
591
+ >;
592
+
593
+ getEvent(
594
+ key: "Claimed"
595
+ ): TypedContractEvent<
596
+ ClaimedEvent.InputTuple,
597
+ ClaimedEvent.OutputTuple,
598
+ ClaimedEvent.OutputObject
599
+ >;
600
+ getEvent(
601
+ key: "Closed"
602
+ ): TypedContractEvent<
603
+ ClosedEvent.InputTuple,
604
+ ClosedEvent.OutputTuple,
605
+ ClosedEvent.OutputObject
606
+ >;
607
+ getEvent(
608
+ key: "Deposited"
609
+ ): TypedContractEvent<
610
+ DepositedEvent.InputTuple,
611
+ DepositedEvent.OutputTuple,
612
+ DepositedEvent.OutputObject
613
+ >;
614
+ getEvent(
615
+ key: "Fronted"
616
+ ): TypedContractEvent<
617
+ FrontedEvent.InputTuple,
618
+ FrontedEvent.OutputTuple,
619
+ FrontedEvent.OutputObject
620
+ >;
621
+ getEvent(
622
+ key: "Opened"
623
+ ): TypedContractEvent<
624
+ OpenedEvent.InputTuple,
625
+ OpenedEvent.OutputTuple,
626
+ OpenedEvent.OutputObject
627
+ >;
628
+
629
+ filters: {
630
+ "Claimed(bytes32,address,bytes32,address,bytes32,address,uint32,uint64,uint64)": TypedContractEvent<
631
+ ClaimedEvent.InputTuple,
632
+ ClaimedEvent.OutputTuple,
633
+ ClaimedEvent.OutputObject
634
+ >;
635
+ Claimed: TypedContractEvent<
636
+ ClaimedEvent.InputTuple,
637
+ ClaimedEvent.OutputTuple,
638
+ ClaimedEvent.OutputObject
639
+ >;
640
+
641
+ "Closed(address,uint96,bytes32,bytes)": TypedContractEvent<
642
+ ClosedEvent.InputTuple,
643
+ ClosedEvent.OutputTuple,
644
+ ClosedEvent.OutputObject
645
+ >;
646
+ Closed: TypedContractEvent<
647
+ ClosedEvent.InputTuple,
648
+ ClosedEvent.OutputTuple,
649
+ ClosedEvent.OutputObject
650
+ >;
651
+
652
+ "Deposited(bytes32,uint32,uint64,uint64)": TypedContractEvent<
653
+ DepositedEvent.InputTuple,
654
+ DepositedEvent.OutputTuple,
655
+ DepositedEvent.OutputObject
656
+ >;
657
+ Deposited: TypedContractEvent<
658
+ DepositedEvent.InputTuple,
659
+ DepositedEvent.OutputTuple,
660
+ DepositedEvent.OutputObject
661
+ >;
662
+
663
+ "Fronted(bytes32,address,bytes32,address,bytes32,uint64,uint64)": TypedContractEvent<
664
+ FrontedEvent.InputTuple,
665
+ FrontedEvent.OutputTuple,
666
+ FrontedEvent.OutputObject
667
+ >;
668
+ Fronted: TypedContractEvent<
669
+ FrontedEvent.InputTuple,
670
+ FrontedEvent.OutputTuple,
671
+ FrontedEvent.OutputObject
672
+ >;
673
+
674
+ "Opened(address,uint96,bytes32,uint32,tuple)": TypedContractEvent<
675
+ OpenedEvent.InputTuple,
676
+ OpenedEvent.OutputTuple,
677
+ OpenedEvent.OutputObject
678
+ >;
679
+ Opened: TypedContractEvent<
680
+ OpenedEvent.InputTuple,
681
+ OpenedEvent.OutputTuple,
682
+ OpenedEvent.OutputObject
683
+ >;
684
+ };
685
+ }