@instadapp/interop-x 0.0.0-dev.a861339 → 0.0.0-dev.a9cd1d2

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 (44) hide show
  1. package/dist/package.json +12 -11
  2. package/dist/src/abi/index.js +2 -2
  3. package/dist/src/abi/interopX.json +1436 -0
  4. package/dist/src/api/index.js +1 -1
  5. package/dist/src/constants/addresses.js +2 -7
  6. package/dist/src/constants/tokens.js +62 -39
  7. package/dist/src/db/models/transaction.js +10 -10
  8. package/dist/src/gnosis/actions/withdraw/index.js +106 -33
  9. package/dist/src/gnosis/index.js +3 -3
  10. package/dist/src/index.js +1 -1
  11. package/dist/src/tasks/{InteropXContract/SyncBridgeRequestEvents.js → InteropX/SyncLogSubmitEvents.js} +20 -14
  12. package/dist/src/tasks/Transactions/SyncTransactionStatusTask.js +4 -2
  13. package/dist/src/tasks/index.js +4 -10
  14. package/dist/src/typechain/{InteropXContract.js → InteropX.js} +0 -0
  15. package/dist/src/typechain/factories/InteropX__factory.js +1928 -0
  16. package/dist/src/typechain/factories/index.js +3 -3
  17. package/dist/src/typechain/index.js +3 -3
  18. package/dist/src/utils/index.js +36 -9
  19. package/package.json +12 -11
  20. package/src/abi/index.ts +2 -2
  21. package/src/abi/interopX.json +1436 -0
  22. package/src/api/index.ts +1 -1
  23. package/src/constants/addresses.ts +3 -8
  24. package/src/constants/tokens.ts +63 -40
  25. package/src/db/models/transaction.ts +29 -34
  26. package/src/gnosis/actions/withdraw/index.ts +141 -42
  27. package/src/gnosis/index.ts +3 -3
  28. package/src/tasks/{InteropXContract/SyncBridgeRequestEvents.ts → InteropX/SyncLogSubmitEvents.ts} +39 -19
  29. package/src/tasks/Transactions/SyncTransactionStatusTask.ts +4 -2
  30. package/src/tasks/index.ts +5 -13
  31. package/src/typechain/InteropX.ts +1216 -0
  32. package/src/typechain/factories/InteropX__factory.ts +1932 -0
  33. package/src/typechain/factories/index.ts +1 -1
  34. package/src/typechain/index.ts +2 -2
  35. package/src/utils/index.ts +88 -39
  36. package/dist/src/abi/interopXContract.json +0 -391
  37. package/dist/src/tasks/InteropXContract/ProcessBridgeRequestEvents.js +0 -147
  38. package/dist/src/tasks/InteropXContract/SyncBridgeRequestSentEvents.js +0 -80
  39. package/dist/src/typechain/factories/InteropXContract__factory.js +0 -526
  40. package/src/abi/interopXContract.json +0 -391
  41. package/src/tasks/InteropXContract/ProcessBridgeRequestEvents.ts +0 -211
  42. package/src/tasks/InteropXContract/SyncBridgeRequestSentEvents.ts +0 -112
  43. package/src/typechain/InteropXContract.ts +0 -524
  44. package/src/typechain/factories/InteropXContract__factory.ts +0 -533
@@ -1,533 +0,0 @@
1
- /* Autogenerated file. Do not edit manually. */
2
- /* tslint:disable */
3
- /* eslint-disable */
4
-
5
- import { Contract, Signer, utils } from "ethers";
6
- import type { Provider } from "@ethersproject/providers";
7
- import type {
8
- InteropXContract,
9
- InteropXContractInterface,
10
- } from "../InteropXContract";
11
-
12
- const _abi = [
13
- {
14
- anonymous: false,
15
- inputs: [
16
- {
17
- indexed: true,
18
- internalType: "address",
19
- name: "bridger",
20
- type: "address",
21
- },
22
- {
23
- components: [
24
- {
25
- components: [
26
- {
27
- internalType: "address",
28
- name: "sourceToken",
29
- type: "address",
30
- },
31
- {
32
- internalType: "address",
33
- name: "targetToken",
34
- type: "address",
35
- },
36
- {
37
- internalType: "uint256",
38
- name: "amount",
39
- type: "uint256",
40
- },
41
- ],
42
- internalType: "struct InteropXContractBeta.TokenInfo[]",
43
- name: "supply",
44
- type: "tuple[]",
45
- },
46
- {
47
- components: [
48
- {
49
- internalType: "address",
50
- name: "sourceToken",
51
- type: "address",
52
- },
53
- {
54
- internalType: "address",
55
- name: "targetToken",
56
- type: "address",
57
- },
58
- {
59
- internalType: "uint256",
60
- name: "amount",
61
- type: "uint256",
62
- },
63
- ],
64
- internalType: "struct InteropXContractBeta.TokenInfo[]",
65
- name: "withdraw",
66
- type: "tuple[]",
67
- },
68
- ],
69
- indexed: false,
70
- internalType: "struct InteropXContractBeta.Position",
71
- name: "position",
72
- type: "tuple",
73
- },
74
- {
75
- indexed: true,
76
- internalType: "uint32",
77
- name: "sourceChainId",
78
- type: "uint32",
79
- },
80
- {
81
- indexed: false,
82
- internalType: "uint32",
83
- name: "targetChainId",
84
- type: "uint32",
85
- },
86
- {
87
- indexed: true,
88
- internalType: "bytes32",
89
- name: "requestTransactionHash",
90
- type: "bytes32",
91
- },
92
- {
93
- indexed: false,
94
- internalType: "bytes",
95
- name: "metadata",
96
- type: "bytes",
97
- },
98
- ],
99
- name: "LogBridgeCommitted",
100
- type: "event",
101
- },
102
- {
103
- anonymous: false,
104
- inputs: [
105
- {
106
- indexed: true,
107
- internalType: "address",
108
- name: "bridger",
109
- type: "address",
110
- },
111
- {
112
- components: [
113
- {
114
- components: [
115
- {
116
- internalType: "address",
117
- name: "sourceToken",
118
- type: "address",
119
- },
120
- {
121
- internalType: "address",
122
- name: "targetToken",
123
- type: "address",
124
- },
125
- {
126
- internalType: "uint256",
127
- name: "amount",
128
- type: "uint256",
129
- },
130
- ],
131
- internalType: "struct InteropXContractBeta.TokenInfo[]",
132
- name: "supply",
133
- type: "tuple[]",
134
- },
135
- {
136
- components: [
137
- {
138
- internalType: "address",
139
- name: "sourceToken",
140
- type: "address",
141
- },
142
- {
143
- internalType: "address",
144
- name: "targetToken",
145
- type: "address",
146
- },
147
- {
148
- internalType: "uint256",
149
- name: "amount",
150
- type: "uint256",
151
- },
152
- ],
153
- internalType: "struct InteropXContractBeta.TokenInfo[]",
154
- name: "withdraw",
155
- type: "tuple[]",
156
- },
157
- ],
158
- indexed: false,
159
- internalType: "struct InteropXContractBeta.Position",
160
- name: "position",
161
- type: "tuple",
162
- },
163
- {
164
- indexed: false,
165
- internalType: "uint256",
166
- name: "sourceChainId",
167
- type: "uint256",
168
- },
169
- {
170
- indexed: true,
171
- internalType: "uint256",
172
- name: "targetChainId",
173
- type: "uint256",
174
- },
175
- {
176
- indexed: true,
177
- internalType: "bytes32",
178
- name: "requestTransactionHash",
179
- type: "bytes32",
180
- },
181
- {
182
- indexed: false,
183
- internalType: "bytes32",
184
- name: "targetCommittedTransactionHash",
185
- type: "bytes32",
186
- },
187
- {
188
- indexed: false,
189
- internalType: "bytes",
190
- name: "metadata",
191
- type: "bytes",
192
- },
193
- ],
194
- name: "LogBridgeCompleted",
195
- type: "event",
196
- },
197
- {
198
- anonymous: false,
199
- inputs: [
200
- {
201
- indexed: true,
202
- internalType: "address",
203
- name: "bridger",
204
- type: "address",
205
- },
206
- {
207
- components: [
208
- {
209
- components: [
210
- {
211
- internalType: "address",
212
- name: "sourceToken",
213
- type: "address",
214
- },
215
- {
216
- internalType: "address",
217
- name: "targetToken",
218
- type: "address",
219
- },
220
- {
221
- internalType: "uint256",
222
- name: "amount",
223
- type: "uint256",
224
- },
225
- ],
226
- internalType: "struct InteropXContractBeta.TokenInfo[]",
227
- name: "supply",
228
- type: "tuple[]",
229
- },
230
- {
231
- components: [
232
- {
233
- internalType: "address",
234
- name: "sourceToken",
235
- type: "address",
236
- },
237
- {
238
- internalType: "address",
239
- name: "targetToken",
240
- type: "address",
241
- },
242
- {
243
- internalType: "uint256",
244
- name: "amount",
245
- type: "uint256",
246
- },
247
- ],
248
- internalType: "struct InteropXContractBeta.TokenInfo[]",
249
- name: "withdraw",
250
- type: "tuple[]",
251
- },
252
- ],
253
- indexed: false,
254
- internalType: "struct InteropXContractBeta.Position",
255
- name: "position",
256
- type: "tuple",
257
- },
258
- {
259
- indexed: false,
260
- internalType: "uint256",
261
- name: "sourceChainId",
262
- type: "uint256",
263
- },
264
- {
265
- indexed: true,
266
- internalType: "uint256",
267
- name: "targetChainId",
268
- type: "uint256",
269
- },
270
- {
271
- indexed: false,
272
- internalType: "bytes",
273
- name: "metadata",
274
- type: "bytes",
275
- },
276
- ],
277
- name: "LogBridgeRequest",
278
- type: "event",
279
- },
280
- {
281
- anonymous: false,
282
- inputs: [
283
- {
284
- indexed: true,
285
- internalType: "address",
286
- name: "bridger",
287
- type: "address",
288
- },
289
- {
290
- components: [
291
- {
292
- components: [
293
- {
294
- internalType: "address",
295
- name: "sourceToken",
296
- type: "address",
297
- },
298
- {
299
- internalType: "address",
300
- name: "targetToken",
301
- type: "address",
302
- },
303
- {
304
- internalType: "uint256",
305
- name: "amount",
306
- type: "uint256",
307
- },
308
- ],
309
- internalType: "struct InteropXContractBeta.TokenInfo[]",
310
- name: "supply",
311
- type: "tuple[]",
312
- },
313
- {
314
- components: [
315
- {
316
- internalType: "address",
317
- name: "sourceToken",
318
- type: "address",
319
- },
320
- {
321
- internalType: "address",
322
- name: "targetToken",
323
- type: "address",
324
- },
325
- {
326
- internalType: "uint256",
327
- name: "amount",
328
- type: "uint256",
329
- },
330
- ],
331
- internalType: "struct InteropXContractBeta.TokenInfo[]",
332
- name: "withdraw",
333
- type: "tuple[]",
334
- },
335
- ],
336
- indexed: false,
337
- internalType: "struct InteropXContractBeta.Position",
338
- name: "position",
339
- type: "tuple",
340
- },
341
- {
342
- indexed: false,
343
- internalType: "uint32",
344
- name: "sourceChainId",
345
- type: "uint32",
346
- },
347
- {
348
- indexed: true,
349
- internalType: "uint32",
350
- name: "targetChainId",
351
- type: "uint32",
352
- },
353
- {
354
- indexed: true,
355
- internalType: "bytes32",
356
- name: "requestTransactionHash",
357
- type: "bytes32",
358
- },
359
- {
360
- indexed: false,
361
- internalType: "bytes",
362
- name: "metadata",
363
- type: "bytes",
364
- },
365
- ],
366
- name: "LogBridgeRequestSent",
367
- type: "event",
368
- },
369
- {
370
- inputs: [],
371
- name: "_vnonce",
372
- outputs: [
373
- {
374
- internalType: "uint256",
375
- name: "",
376
- type: "uint256",
377
- },
378
- ],
379
- stateMutability: "view",
380
- type: "function",
381
- },
382
- {
383
- inputs: [
384
- {
385
- internalType: "address",
386
- name: "to_",
387
- type: "address",
388
- },
389
- {
390
- internalType: "address",
391
- name: "sourceToken_",
392
- type: "address",
393
- },
394
- {
395
- internalType: "address",
396
- name: "targetToken_",
397
- type: "address",
398
- },
399
- {
400
- internalType: "uint256",
401
- name: "amount_",
402
- type: "uint256",
403
- },
404
- {
405
- internalType: "uint32",
406
- name: "targetChainId_",
407
- type: "uint32",
408
- },
409
- {
410
- internalType: "bytes32",
411
- name: "transactionHash_",
412
- type: "bytes32",
413
- },
414
- {
415
- internalType: "bytes",
416
- name: "metadata_",
417
- type: "bytes",
418
- },
419
- ],
420
- name: "completeBridge",
421
- outputs: [],
422
- stateMutability: "nonpayable",
423
- type: "function",
424
- },
425
- {
426
- inputs: [
427
- {
428
- internalType: "address",
429
- name: "sourceToken_",
430
- type: "address",
431
- },
432
- {
433
- internalType: "address",
434
- name: "targetToken_",
435
- type: "address",
436
- },
437
- {
438
- internalType: "uint256",
439
- name: "amount_",
440
- type: "uint256",
441
- },
442
- {
443
- internalType: "uint32",
444
- name: "targetChainId_",
445
- type: "uint32",
446
- },
447
- {
448
- internalType: "bytes",
449
- name: "metadata_",
450
- type: "bytes",
451
- },
452
- ],
453
- name: "requestWithdraw",
454
- outputs: [],
455
- stateMutability: "nonpayable",
456
- type: "function",
457
- },
458
- {
459
- inputs: [
460
- {
461
- internalType: "address",
462
- name: "",
463
- type: "address",
464
- },
465
- ],
466
- name: "whitelistedMapping",
467
- outputs: [
468
- {
469
- internalType: "uint256",
470
- name: "",
471
- type: "uint256",
472
- },
473
- ],
474
- stateMutability: "view",
475
- type: "function",
476
- },
477
- {
478
- inputs: [
479
- {
480
- internalType: "address",
481
- name: "user_",
482
- type: "address",
483
- },
484
- {
485
- internalType: "address",
486
- name: "sourceToken_",
487
- type: "address",
488
- },
489
- {
490
- internalType: "address",
491
- name: "targetToken_",
492
- type: "address",
493
- },
494
- {
495
- internalType: "uint256",
496
- name: "amount_",
497
- type: "uint256",
498
- },
499
- {
500
- internalType: "uint32",
501
- name: "chainId_",
502
- type: "uint32",
503
- },
504
- {
505
- internalType: "bytes32",
506
- name: "transactionHash_",
507
- type: "bytes32",
508
- },
509
- {
510
- internalType: "bytes",
511
- name: "metadata_",
512
- type: "bytes",
513
- },
514
- ],
515
- name: "withdrawRequested",
516
- outputs: [],
517
- stateMutability: "nonpayable",
518
- type: "function",
519
- },
520
- ];
521
-
522
- export class InteropXContract__factory {
523
- static readonly abi = _abi;
524
- static createInterface(): InteropXContractInterface {
525
- return new utils.Interface(_abi) as InteropXContractInterface;
526
- }
527
- static connect(
528
- address: string,
529
- signerOrProvider: Signer | Provider
530
- ): InteropXContract {
531
- return new Contract(address, _abi, signerOrProvider) as InteropXContract;
532
- }
533
- }