@gitmyabi/weth 1.0.2 → 1.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,381 +1,293 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.StandardToken_json = exports.StandardToken_jsonAbi = void 0;
3
+ exports.WETH9_json = exports.WETH9_jsonAbi = void 0;
4
4
  const viem_1 = require("viem");
5
5
  /**
6
- * StandardToken_json ABI
6
+ * WETH9_json ABI
7
7
  *
8
8
  * This ABI is typed using viem's type system for full type safety.
9
9
  */
10
- exports.StandardToken_jsonAbi = [
10
+ exports.WETH9_jsonAbi = [
11
11
  {
12
+ "constant": true,
12
13
  "inputs": [],
13
- "stateMutability": "nonpayable",
14
- "type": "constructor"
15
- },
16
- {
17
- "anonymous": false,
18
- "inputs": [
19
- {
20
- "indexed": true,
21
- "internalType": "address",
22
- "name": "owner",
23
- "type": "address"
24
- },
25
- {
26
- "indexed": true,
27
- "internalType": "address",
28
- "name": "spender",
29
- "type": "address"
30
- },
31
- {
32
- "indexed": false,
33
- "internalType": "uint256",
34
- "name": "value",
35
- "type": "uint256"
36
- }
37
- ],
38
- "name": "Approval",
39
- "type": "event"
40
- },
41
- {
42
- "anonymous": false,
43
- "inputs": [
44
- {
45
- "indexed": false,
46
- "internalType": "uint8",
47
- "name": "version",
48
- "type": "uint8"
49
- }
50
- ],
51
- "name": "Initialized",
52
- "type": "event"
53
- },
54
- {
55
- "anonymous": false,
56
- "inputs": [
57
- {
58
- "indexed": true,
59
- "internalType": "address",
60
- "name": "from",
61
- "type": "address"
62
- },
63
- {
64
- "indexed": true,
65
- "internalType": "address",
66
- "name": "to",
67
- "type": "address"
68
- },
69
- {
70
- "indexed": false,
71
- "internalType": "uint256",
72
- "name": "value",
73
- "type": "uint256"
74
- }
75
- ],
76
- "name": "Transfer",
77
- "type": "event"
78
- },
79
- {
80
- "inputs": [
81
- {
82
- "internalType": "address",
83
- "name": "owner",
84
- "type": "address"
85
- },
86
- {
87
- "internalType": "address",
88
- "name": "spender",
89
- "type": "address"
90
- }
91
- ],
92
- "name": "allowance",
14
+ "name": "name",
93
15
  "outputs": [
94
16
  {
95
- "internalType": "uint256",
96
17
  "name": "",
97
- "type": "uint256"
18
+ "type": "string"
98
19
  }
99
20
  ],
21
+ "payable": false,
100
22
  "stateMutability": "view",
101
23
  "type": "function"
102
24
  },
103
25
  {
26
+ "constant": false,
104
27
  "inputs": [
105
28
  {
106
- "internalType": "address",
107
- "name": "spender",
29
+ "name": "guy",
108
30
  "type": "address"
109
31
  },
110
32
  {
111
- "internalType": "uint256",
112
- "name": "amount",
33
+ "name": "wad",
113
34
  "type": "uint256"
114
35
  }
115
36
  ],
116
37
  "name": "approve",
117
38
  "outputs": [
118
39
  {
119
- "internalType": "bool",
120
40
  "name": "",
121
41
  "type": "bool"
122
42
  }
123
43
  ],
44
+ "payable": false,
124
45
  "stateMutability": "nonpayable",
125
46
  "type": "function"
126
47
  },
127
48
  {
128
- "inputs": [
129
- {
130
- "internalType": "address",
131
- "name": "account",
132
- "type": "address"
133
- }
134
- ],
135
- "name": "balanceOf",
49
+ "constant": true,
50
+ "inputs": [],
51
+ "name": "totalSupply",
136
52
  "outputs": [
137
53
  {
138
- "internalType": "uint256",
139
54
  "name": "",
140
55
  "type": "uint256"
141
56
  }
142
57
  ],
58
+ "payable": false,
143
59
  "stateMutability": "view",
144
60
  "type": "function"
145
61
  },
146
62
  {
63
+ "constant": false,
147
64
  "inputs": [
148
65
  {
149
- "internalType": "uint256",
150
- "name": "amount",
66
+ "name": "src",
67
+ "type": "address"
68
+ },
69
+ {
70
+ "name": "dst",
71
+ "type": "address"
72
+ },
73
+ {
74
+ "name": "wad",
151
75
  "type": "uint256"
152
76
  }
153
77
  ],
154
- "name": "burn",
155
- "outputs": [],
78
+ "name": "transferFrom",
79
+ "outputs": [
80
+ {
81
+ "name": "",
82
+ "type": "bool"
83
+ }
84
+ ],
85
+ "payable": false,
156
86
  "stateMutability": "nonpayable",
157
87
  "type": "function"
158
88
  },
159
89
  {
90
+ "constant": false,
160
91
  "inputs": [
161
92
  {
162
- "internalType": "address",
163
- "name": "account",
164
- "type": "address"
165
- },
166
- {
167
- "internalType": "uint256",
168
- "name": "amount",
93
+ "name": "wad",
169
94
  "type": "uint256"
170
95
  }
171
96
  ],
172
- "name": "burnFrom",
97
+ "name": "withdraw",
173
98
  "outputs": [],
99
+ "payable": false,
174
100
  "stateMutability": "nonpayable",
175
101
  "type": "function"
176
102
  },
177
103
  {
104
+ "constant": true,
178
105
  "inputs": [],
179
106
  "name": "decimals",
180
107
  "outputs": [
181
108
  {
182
- "internalType": "uint8",
183
109
  "name": "",
184
110
  "type": "uint8"
185
111
  }
186
112
  ],
113
+ "payable": false,
187
114
  "stateMutability": "view",
188
115
  "type": "function"
189
116
  },
190
117
  {
118
+ "constant": true,
191
119
  "inputs": [
192
120
  {
193
- "internalType": "address",
194
- "name": "spender",
121
+ "name": "",
195
122
  "type": "address"
196
- },
123
+ }
124
+ ],
125
+ "name": "balanceOf",
126
+ "outputs": [
197
127
  {
198
- "internalType": "uint256",
199
- "name": "subtractedValue",
128
+ "name": "",
200
129
  "type": "uint256"
201
130
  }
202
131
  ],
203
- "name": "decreaseAllowance",
132
+ "payable": false,
133
+ "stateMutability": "view",
134
+ "type": "function"
135
+ },
136
+ {
137
+ "constant": true,
138
+ "inputs": [],
139
+ "name": "symbol",
204
140
  "outputs": [
205
141
  {
206
- "internalType": "bool",
207
142
  "name": "",
208
- "type": "bool"
143
+ "type": "string"
209
144
  }
210
145
  ],
211
- "stateMutability": "nonpayable",
146
+ "payable": false,
147
+ "stateMutability": "view",
212
148
  "type": "function"
213
149
  },
214
150
  {
151
+ "constant": false,
215
152
  "inputs": [
216
153
  {
217
- "internalType": "address",
218
- "name": "spender",
154
+ "name": "dst",
219
155
  "type": "address"
220
156
  },
221
157
  {
222
- "internalType": "uint256",
223
- "name": "addedValue",
158
+ "name": "wad",
224
159
  "type": "uint256"
225
160
  }
226
161
  ],
227
- "name": "increaseAllowance",
162
+ "name": "transfer",
228
163
  "outputs": [
229
164
  {
230
- "internalType": "bool",
231
165
  "name": "",
232
166
  "type": "bool"
233
167
  }
234
168
  ],
169
+ "payable": false,
235
170
  "stateMutability": "nonpayable",
236
171
  "type": "function"
237
172
  },
238
173
  {
174
+ "constant": false,
175
+ "inputs": [],
176
+ "name": "deposit",
177
+ "outputs": [],
178
+ "payable": true,
179
+ "stateMutability": "payable",
180
+ "type": "function"
181
+ },
182
+ {
183
+ "constant": true,
239
184
  "inputs": [
240
185
  {
241
- "internalType": "address",
242
- "name": "_owner",
186
+ "name": "",
243
187
  "type": "address"
244
188
  },
245
189
  {
246
- "internalType": "string",
247
- "name": "_name",
248
- "type": "string"
249
- },
250
- {
251
- "internalType": "string",
252
- "name": "_symbol",
253
- "type": "string"
254
- },
255
- {
256
- "internalType": "uint8",
257
- "name": "_decimals",
258
- "type": "uint8"
259
- },
260
- {
261
- "internalType": "uint256",
262
- "name": "_initialSupply",
263
- "type": "uint256"
190
+ "name": "",
191
+ "type": "address"
264
192
  }
265
193
  ],
266
- "name": "initialize",
267
- "outputs": [],
268
- "stateMutability": "nonpayable",
269
- "type": "function"
270
- },
271
- {
272
- "inputs": [],
273
- "name": "maxSupply",
194
+ "name": "allowance",
274
195
  "outputs": [
275
196
  {
276
- "internalType": "uint256",
277
197
  "name": "",
278
198
  "type": "uint256"
279
199
  }
280
200
  ],
201
+ "payable": false,
281
202
  "stateMutability": "view",
282
203
  "type": "function"
283
204
  },
284
205
  {
285
- "inputs": [],
286
- "name": "name",
287
- "outputs": [
288
- {
289
- "internalType": "string",
290
- "name": "",
291
- "type": "string"
292
- }
293
- ],
294
- "stateMutability": "view",
295
- "type": "function"
206
+ "payable": true,
207
+ "stateMutability": "payable",
208
+ "type": "fallback"
296
209
  },
297
210
  {
298
- "inputs": [],
299
- "name": "symbol",
300
- "outputs": [
211
+ "anonymous": false,
212
+ "inputs": [
301
213
  {
302
- "internalType": "string",
303
- "name": "",
304
- "type": "string"
214
+ "indexed": true,
215
+ "name": "src",
216
+ "type": "address"
217
+ },
218
+ {
219
+ "indexed": true,
220
+ "name": "guy",
221
+ "type": "address"
222
+ },
223
+ {
224
+ "indexed": false,
225
+ "name": "wad",
226
+ "type": "uint256"
305
227
  }
306
228
  ],
307
- "stateMutability": "view",
308
- "type": "function"
229
+ "name": "Approval",
230
+ "type": "event"
309
231
  },
310
232
  {
311
- "inputs": [],
312
- "name": "totalSupply",
313
- "outputs": [
233
+ "anonymous": false,
234
+ "inputs": [
314
235
  {
315
- "internalType": "uint256",
316
- "name": "",
236
+ "indexed": true,
237
+ "name": "src",
238
+ "type": "address"
239
+ },
240
+ {
241
+ "indexed": true,
242
+ "name": "dst",
243
+ "type": "address"
244
+ },
245
+ {
246
+ "indexed": false,
247
+ "name": "wad",
317
248
  "type": "uint256"
318
249
  }
319
250
  ],
320
- "stateMutability": "view",
321
- "type": "function"
251
+ "name": "Transfer",
252
+ "type": "event"
322
253
  },
323
254
  {
255
+ "anonymous": false,
324
256
  "inputs": [
325
257
  {
326
- "internalType": "address",
327
- "name": "to",
258
+ "indexed": true,
259
+ "name": "dst",
328
260
  "type": "address"
329
261
  },
330
262
  {
331
- "internalType": "uint256",
332
- "name": "amount",
263
+ "indexed": false,
264
+ "name": "wad",
333
265
  "type": "uint256"
334
266
  }
335
267
  ],
336
- "name": "transfer",
337
- "outputs": [
338
- {
339
- "internalType": "bool",
340
- "name": "",
341
- "type": "bool"
342
- }
343
- ],
344
- "stateMutability": "nonpayable",
345
- "type": "function"
268
+ "name": "Deposit",
269
+ "type": "event"
346
270
  },
347
271
  {
272
+ "anonymous": false,
348
273
  "inputs": [
349
274
  {
350
- "internalType": "address",
351
- "name": "from",
352
- "type": "address"
353
- },
354
- {
355
- "internalType": "address",
356
- "name": "to",
275
+ "indexed": true,
276
+ "name": "src",
357
277
  "type": "address"
358
278
  },
359
279
  {
360
- "internalType": "uint256",
361
- "name": "amount",
280
+ "indexed": false,
281
+ "name": "wad",
362
282
  "type": "uint256"
363
283
  }
364
284
  ],
365
- "name": "transferFrom",
366
- "outputs": [
367
- {
368
- "internalType": "bool",
369
- "name": "",
370
- "type": "bool"
371
- }
372
- ],
373
- "stateMutability": "nonpayable",
374
- "type": "function"
285
+ "name": "Withdrawal",
286
+ "type": "event"
375
287
  }
376
288
  ];
377
289
  /**
378
- * StandardToken_json Contract Class
290
+ * WETH9_json Contract Class
379
291
  *
380
292
  * Provides a class-based API similar to TypeChain for interacting with the contract.
381
293
  *
@@ -383,12 +295,12 @@ exports.StandardToken_jsonAbi = [
383
295
  * ```typescript
384
296
  * import { createPublicClient, createWalletClient, http } from 'viem';
385
297
  * import { mainnet } from 'viem/chains';
386
- * import { StandardToken_json } from 'StandardToken_json';
298
+ * import { WETH9_json } from 'WETH9_json';
387
299
  *
388
300
  * const publicClient = createPublicClient({ chain: mainnet, transport: http() });
389
301
  * const walletClient = createWalletClient({ chain: mainnet, transport: http() });
390
302
  *
391
- * const contract = new StandardToken_json('0x...', { publicClient, walletClient });
303
+ * const contract = new WETH9_json('0x...', { publicClient, walletClient });
392
304
  *
393
305
  * // Read functions
394
306
  * const result = await contract.balanceOf('0x...');
@@ -406,13 +318,13 @@ exports.StandardToken_jsonAbi = [
406
318
  * });
407
319
  * ```
408
320
  */
409
- class StandardToken_json {
321
+ class WETH9_json {
410
322
  constructor(address, clients) {
411
323
  this.contractAddress = address;
412
324
  this.publicClient = clients.publicClient;
413
325
  this.contract = (0, viem_1.getContract)({
414
326
  address,
415
- abi: exports.StandardToken_jsonAbi,
327
+ abi: exports.WETH9_jsonAbi,
416
328
  client: {
417
329
  public: clients.publicClient,
418
330
  wallet: clients.walletClient,
@@ -432,18 +344,18 @@ class StandardToken_json {
432
344
  return this.contract;
433
345
  }
434
346
  /**
435
- * allowance
347
+ * name
436
348
  * view
437
349
  */
438
- async allowance(owner, spender) {
439
- return this.contract.read.allowance([owner, spender]);
350
+ async name() {
351
+ return this.contract.read.name();
440
352
  }
441
353
  /**
442
- * balanceOf
354
+ * totalSupply
443
355
  * view
444
356
  */
445
- async balanceOf(account) {
446
- return this.contract.read.balanceOf([account]);
357
+ async totalSupply() {
358
+ return this.contract.read.totalSupply();
447
359
  }
448
360
  /**
449
361
  * decimals
@@ -453,18 +365,11 @@ class StandardToken_json {
453
365
  return this.contract.read.decimals();
454
366
  }
455
367
  /**
456
- * maxSupply
457
- * view
458
- */
459
- async maxSupply() {
460
- return this.contract.read.maxSupply();
461
- }
462
- /**
463
- * name
368
+ * balanceOf
464
369
  * view
465
370
  */
466
- async name() {
467
- return this.contract.read.name();
371
+ async balanceOf(arg0) {
372
+ return this.contract.read.balanceOf([arg0]);
468
373
  }
469
374
  /**
470
375
  * symbol
@@ -474,99 +379,66 @@ class StandardToken_json {
474
379
  return this.contract.read.symbol();
475
380
  }
476
381
  /**
477
- * totalSupply
382
+ * allowance
478
383
  * view
479
384
  */
480
- async totalSupply() {
481
- return this.contract.read.totalSupply();
385
+ async allowance(arg0, arg1) {
386
+ return this.contract.read.allowance([arg0, arg1]);
482
387
  }
483
388
  /**
484
389
  * approve
485
390
  * nonpayable
486
391
  * @param options Optional transaction parameters (value, gas, nonce, etc.)
487
392
  */
488
- async approve(spender, amount, options) {
393
+ async approve(guy, wad, options) {
489
394
  if (!this.contract.write) {
490
395
  throw new Error('Wallet client is required for write operations');
491
396
  }
492
- return this.contract.write.approve([spender, amount], options);
397
+ return this.contract.write.approve([guy, wad], options);
493
398
  }
494
399
  /**
495
- * burn
496
- * nonpayable
497
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
498
- */
499
- async burn(amount, options) {
500
- if (!this.contract.write) {
501
- throw new Error('Wallet client is required for write operations');
502
- }
503
- return this.contract.write.burn([amount], options);
504
- }
505
- /**
506
- * burnFrom
507
- * nonpayable
508
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
509
- */
510
- async burnFrom(account, amount, options) {
511
- if (!this.contract.write) {
512
- throw new Error('Wallet client is required for write operations');
513
- }
514
- return this.contract.write.burnFrom([account, amount], options);
515
- }
516
- /**
517
- * decreaseAllowance
518
- * nonpayable
519
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
520
- */
521
- async decreaseAllowance(spender, subtractedValue, options) {
522
- if (!this.contract.write) {
523
- throw new Error('Wallet client is required for write operations');
524
- }
525
- return this.contract.write.decreaseAllowance([spender, subtractedValue], options);
526
- }
527
- /**
528
- * increaseAllowance
400
+ * transferFrom
529
401
  * nonpayable
530
402
  * @param options Optional transaction parameters (value, gas, nonce, etc.)
531
403
  */
532
- async increaseAllowance(spender, addedValue, options) {
404
+ async transferFrom(src, dst, wad, options) {
533
405
  if (!this.contract.write) {
534
406
  throw new Error('Wallet client is required for write operations');
535
407
  }
536
- return this.contract.write.increaseAllowance([spender, addedValue], options);
408
+ return this.contract.write.transferFrom([src, dst, wad], options);
537
409
  }
538
410
  /**
539
- * initialize
411
+ * withdraw
540
412
  * nonpayable
541
413
  * @param options Optional transaction parameters (value, gas, nonce, etc.)
542
414
  */
543
- async initialize(_owner, _name, _symbol, _decimals, _initialSupply, options) {
415
+ async withdraw(wad, options) {
544
416
  if (!this.contract.write) {
545
417
  throw new Error('Wallet client is required for write operations');
546
418
  }
547
- return this.contract.write.initialize([_owner, _name, _symbol, _decimals, _initialSupply], options);
419
+ return this.contract.write.withdraw([wad], options);
548
420
  }
549
421
  /**
550
422
  * transfer
551
423
  * nonpayable
552
424
  * @param options Optional transaction parameters (value, gas, nonce, etc.)
553
425
  */
554
- async transfer(to, amount, options) {
426
+ async transfer(dst, wad, options) {
555
427
  if (!this.contract.write) {
556
428
  throw new Error('Wallet client is required for write operations');
557
429
  }
558
- return this.contract.write.transfer([to, amount], options);
430
+ return this.contract.write.transfer([dst, wad], options);
559
431
  }
560
432
  /**
561
- * transferFrom
562
- * nonpayable
433
+ * deposit
434
+ * payable
563
435
  * @param options Optional transaction parameters (value, gas, nonce, etc.)
564
436
  */
565
- async transferFrom(from, to, amount, options) {
437
+ async deposit(options) {
566
438
  if (!this.contract.write) {
567
439
  throw new Error('Wallet client is required for write operations');
568
440
  }
569
- return this.contract.write.transferFrom([from, to, amount], options);
441
+ return this.contract.write.deposit(options);
570
442
  }
571
443
  /**
572
444
  * Simulate contract write operations (dry-run without sending transaction)
@@ -587,64 +459,40 @@ class StandardToken_json {
587
459
  * Returns gas estimate and result without sending transaction
588
460
  * @param options Optional transaction parameters (value, gas, nonce, etc.)
589
461
  */
590
- async approve(spender, amount, options) {
591
- return contract.simulate.approve([spender, amount], options);
592
- },
593
- /**
594
- * Simulate burn
595
- * Returns gas estimate and result without sending transaction
596
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
597
- */
598
- async burn(amount, options) {
599
- return contract.simulate.burn([amount], options);
600
- },
601
- /**
602
- * Simulate burnFrom
603
- * Returns gas estimate and result without sending transaction
604
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
605
- */
606
- async burnFrom(account, amount, options) {
607
- return contract.simulate.burnFrom([account, amount], options);
462
+ async approve(guy, wad, options) {
463
+ return contract.simulate.approve([guy, wad], options);
608
464
  },
609
465
  /**
610
- * Simulate decreaseAllowance
611
- * Returns gas estimate and result without sending transaction
612
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
613
- */
614
- async decreaseAllowance(spender, subtractedValue, options) {
615
- return contract.simulate.decreaseAllowance([spender, subtractedValue], options);
616
- },
617
- /**
618
- * Simulate increaseAllowance
466
+ * Simulate transferFrom
619
467
  * Returns gas estimate and result without sending transaction
620
468
  * @param options Optional transaction parameters (value, gas, nonce, etc.)
621
469
  */
622
- async increaseAllowance(spender, addedValue, options) {
623
- return contract.simulate.increaseAllowance([spender, addedValue], options);
470
+ async transferFrom(src, dst, wad, options) {
471
+ return contract.simulate.transferFrom([src, dst, wad], options);
624
472
  },
625
473
  /**
626
- * Simulate initialize
474
+ * Simulate withdraw
627
475
  * Returns gas estimate and result without sending transaction
628
476
  * @param options Optional transaction parameters (value, gas, nonce, etc.)
629
477
  */
630
- async initialize(_owner, _name, _symbol, _decimals, _initialSupply, options) {
631
- return contract.simulate.initialize([_owner, _name, _symbol, _decimals, _initialSupply], options);
478
+ async withdraw(wad, options) {
479
+ return contract.simulate.withdraw([wad], options);
632
480
  },
633
481
  /**
634
482
  * Simulate transfer
635
483
  * Returns gas estimate and result without sending transaction
636
484
  * @param options Optional transaction parameters (value, gas, nonce, etc.)
637
485
  */
638
- async transfer(to, amount, options) {
639
- return contract.simulate.transfer([to, amount], options);
486
+ async transfer(dst, wad, options) {
487
+ return contract.simulate.transfer([dst, wad], options);
640
488
  },
641
489
  /**
642
- * Simulate transferFrom
490
+ * Simulate deposit
643
491
  * Returns gas estimate and result without sending transaction
644
492
  * @param options Optional transaction parameters (value, gas, nonce, etc.)
645
493
  */
646
- async transferFrom(from, to, amount, options) {
647
- return contract.simulate.transferFrom([from, to, amount], options);
494
+ async deposit(options) {
495
+ return contract.simulate.deposit(options);
648
496
  }
649
497
  };
650
498
  }
@@ -671,7 +519,7 @@ class StandardToken_json {
671
519
  Approval: (callback, filter) => {
672
520
  return this.publicClient.watchContractEvent({
673
521
  address: this.contractAddress,
674
- abi: exports.StandardToken_jsonAbi,
522
+ abi: exports.WETH9_jsonAbi,
675
523
  eventName: 'Approval',
676
524
  args: filter,
677
525
  onLogs: (logs) => {
@@ -682,16 +530,17 @@ class StandardToken_json {
682
530
  });
683
531
  },
684
532
  /**
685
- * Watch Initialized events
533
+ * Watch Transfer events
686
534
  * @param callback Function to call when event is emitted
687
535
  * @param filter Optional filter for indexed parameters
688
536
  * @returns Unwatch function to stop listening
689
537
  */
690
- Initialized: (callback) => {
538
+ Transfer: (callback, filter) => {
691
539
  return this.publicClient.watchContractEvent({
692
540
  address: this.contractAddress,
693
- abi: exports.StandardToken_jsonAbi,
694
- eventName: 'Initialized',
541
+ abi: exports.WETH9_jsonAbi,
542
+ eventName: 'Transfer',
543
+ args: filter,
695
544
  onLogs: (logs) => {
696
545
  logs.forEach((log) => {
697
546
  callback(log.args);
@@ -700,16 +549,35 @@ class StandardToken_json {
700
549
  });
701
550
  },
702
551
  /**
703
- * Watch Transfer events
552
+ * Watch Deposit events
704
553
  * @param callback Function to call when event is emitted
705
554
  * @param filter Optional filter for indexed parameters
706
555
  * @returns Unwatch function to stop listening
707
556
  */
708
- Transfer: (callback, filter) => {
557
+ Deposit: (callback, filter) => {
709
558
  return this.publicClient.watchContractEvent({
710
559
  address: this.contractAddress,
711
- abi: exports.StandardToken_jsonAbi,
712
- eventName: 'Transfer',
560
+ abi: exports.WETH9_jsonAbi,
561
+ eventName: 'Deposit',
562
+ args: filter,
563
+ onLogs: (logs) => {
564
+ logs.forEach((log) => {
565
+ callback(log.args);
566
+ });
567
+ },
568
+ });
569
+ },
570
+ /**
571
+ * Watch Withdrawal events
572
+ * @param callback Function to call when event is emitted
573
+ * @param filter Optional filter for indexed parameters
574
+ * @returns Unwatch function to stop listening
575
+ */
576
+ Withdrawal: (callback, filter) => {
577
+ return this.publicClient.watchContractEvent({
578
+ address: this.contractAddress,
579
+ abi: exports.WETH9_jsonAbi,
580
+ eventName: 'Withdrawal',
713
581
  args: filter,
714
582
  onLogs: (logs) => {
715
583
  logs.forEach((log) => {
@@ -721,4 +589,4 @@ class StandardToken_json {
721
589
  };
722
590
  }
723
591
  }
724
- exports.StandardToken_json = StandardToken_json;
592
+ exports.WETH9_json = WETH9_json;