@pufferfinance/puffer-sdk 1.6.1 → 1.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (87) hide show
  1. package/dist/api/puffer-client.cjs +1 -1
  2. package/dist/api/puffer-client.cjs.map +1 -1
  3. package/dist/api/puffer-client.d.ts +9 -3
  4. package/dist/api/puffer-client.js +65 -51
  5. package/dist/api/puffer-client.js.map +1 -1
  6. package/dist/contracts/abis/mainnet/Accountant.cjs +2 -0
  7. package/dist/contracts/abis/mainnet/Accountant.cjs.map +1 -0
  8. package/dist/contracts/abis/mainnet/Accountant.d.ts +521 -0
  9. package/dist/contracts/abis/mainnet/Accountant.js +494 -0
  10. package/dist/contracts/abis/mainnet/Accountant.js.map +1 -0
  11. package/dist/contracts/abis/mainnet/BoringVault.cjs +2 -0
  12. package/dist/contracts/abis/mainnet/BoringVault.cjs.map +1 -0
  13. package/dist/contracts/abis/mainnet/{PufToken.d.ts → BoringVault.d.ts} +395 -449
  14. package/dist/contracts/abis/mainnet/BoringVault.js +407 -0
  15. package/dist/contracts/abis/mainnet/BoringVault.js.map +1 -0
  16. package/dist/contracts/abis/mainnet/Teller.cjs +2 -0
  17. package/dist/contracts/abis/mainnet/Teller.cjs.map +1 -0
  18. package/dist/contracts/abis/mainnet/Teller.d.ts +541 -0
  19. package/dist/contracts/abis/mainnet/Teller.js +450 -0
  20. package/dist/contracts/abis/mainnet/Teller.js.map +1 -0
  21. package/dist/contracts/abis/nucleus-accountant-abis.cjs +2 -0
  22. package/dist/contracts/abis/nucleus-accountant-abis.cjs.map +1 -0
  23. package/dist/contracts/abis/nucleus-accountant-abis.d.ts +525 -0
  24. package/dist/contracts/abis/nucleus-accountant-abis.js +9 -0
  25. package/dist/contracts/abis/nucleus-accountant-abis.js.map +1 -0
  26. package/dist/contracts/abis/nucleus-boring-vault-abis.cjs +2 -0
  27. package/dist/contracts/abis/nucleus-boring-vault-abis.cjs.map +1 -0
  28. package/dist/contracts/abis/{puf-token-abis.d.ts → nucleus-boring-vault-abis.d.ts} +396 -450
  29. package/dist/contracts/abis/nucleus-boring-vault-abis.js +9 -0
  30. package/dist/contracts/abis/nucleus-boring-vault-abis.js.map +1 -0
  31. package/dist/contracts/abis/nucleus-teller-abis.cjs +2 -0
  32. package/dist/contracts/abis/nucleus-teller-abis.cjs.map +1 -0
  33. package/dist/contracts/abis/nucleus-teller-abis.d.ts +545 -0
  34. package/dist/contracts/abis/nucleus-teller-abis.js +9 -0
  35. package/dist/contracts/abis/nucleus-teller-abis.js.map +1 -0
  36. package/dist/contracts/addresses.cjs +1 -1
  37. package/dist/contracts/addresses.cjs.map +1 -1
  38. package/dist/contracts/addresses.d.ts +6 -0
  39. package/dist/contracts/addresses.js +15 -8
  40. package/dist/contracts/addresses.js.map +1 -1
  41. package/dist/contracts/handlers/erc20-permit-handler.cjs +1 -1
  42. package/dist/contracts/handlers/erc20-permit-handler.cjs.map +1 -1
  43. package/dist/contracts/handlers/erc20-permit-handler.d.ts +2 -2
  44. package/dist/contracts/handlers/erc20-permit-handler.js +4 -4
  45. package/dist/contracts/handlers/erc20-permit-handler.js.map +1 -1
  46. package/dist/contracts/handlers/nucleus-accountant-handler.cjs +2 -0
  47. package/dist/contracts/handlers/nucleus-accountant-handler.cjs.map +1 -0
  48. package/dist/contracts/handlers/nucleus-accountant-handler.d.ts +6702 -0
  49. package/dist/contracts/handlers/nucleus-accountant-handler.js +81 -0
  50. package/dist/contracts/handlers/nucleus-accountant-handler.js.map +1 -0
  51. package/dist/contracts/handlers/nucleus-boring-vault-handler.cjs +2 -0
  52. package/dist/contracts/handlers/nucleus-boring-vault-handler.cjs.map +1 -0
  53. package/dist/contracts/handlers/{puf-token-handler.d.ts → nucleus-boring-vault-handler.d.ts} +462 -517
  54. package/dist/contracts/handlers/nucleus-boring-vault-handler.js +159 -0
  55. package/dist/contracts/handlers/nucleus-boring-vault-handler.js.map +1 -0
  56. package/dist/contracts/handlers/nucleus-teller-handler.cjs +2 -0
  57. package/dist/contracts/handlers/nucleus-teller-handler.cjs.map +1 -0
  58. package/dist/contracts/handlers/nucleus-teller-handler.d.ts +6764 -0
  59. package/dist/contracts/handlers/nucleus-teller-handler.js +145 -0
  60. package/dist/contracts/handlers/nucleus-teller-handler.js.map +1 -0
  61. package/dist/contracts/handlers/puf-locker-handler.cjs.map +1 -1
  62. package/dist/contracts/handlers/puf-locker-handler.d.ts +5 -5
  63. package/dist/contracts/handlers/puf-locker-handler.js.map +1 -1
  64. package/dist/contracts/tokens.cjs +1 -1
  65. package/dist/contracts/tokens.cjs.map +1 -1
  66. package/dist/contracts/tokens.d.ts +3 -24
  67. package/dist/contracts/tokens.js +38 -96
  68. package/dist/contracts/tokens.js.map +1 -1
  69. package/dist/main.cjs +1 -1
  70. package/dist/main.d.ts +0 -1
  71. package/dist/main.js +23 -26
  72. package/dist/main.js.map +1 -1
  73. package/dist/utils/version.cjs +1 -1
  74. package/dist/utils/version.js +1 -1
  75. package/package.json +1 -1
  76. package/dist/contracts/abis/mainnet/PufToken.cjs +0 -2
  77. package/dist/contracts/abis/mainnet/PufToken.cjs.map +0 -1
  78. package/dist/contracts/abis/mainnet/PufToken.js +0 -883
  79. package/dist/contracts/abis/mainnet/PufToken.js.map +0 -1
  80. package/dist/contracts/abis/puf-token-abis.cjs +0 -2
  81. package/dist/contracts/abis/puf-token-abis.cjs.map +0 -1
  82. package/dist/contracts/abis/puf-token-abis.js +0 -10
  83. package/dist/contracts/abis/puf-token-abis.js.map +0 -1
  84. package/dist/contracts/handlers/puf-token-handler.cjs +0 -2
  85. package/dist/contracts/handlers/puf-token-handler.cjs.map +0 -1
  86. package/dist/contracts/handlers/puf-token-handler.js +0 -174
  87. package/dist/contracts/handlers/puf-token-handler.js.map +0 -1
@@ -1,20 +1,25 @@
1
- import { WalletClient, PublicClient, GetContractReturnType, Address } from 'viem';
1
+ import { WalletClient, PublicClient, Address, GetContractReturnType } from 'viem';
2
2
  import { Chain, ViemChain } from '../../chains/constants';
3
- import { PufToken } from '../tokens';
3
+ export type PermitParams = {
4
+ owner: Address;
5
+ spender: Address;
6
+ value: bigint;
7
+ deadline: bigint;
8
+ v: number;
9
+ r: Address;
10
+ s: Address;
11
+ };
4
12
  /**
5
- * Handler for the `PufToken` contract exposing methods to interact with
6
- * the contract for each of the wrapped PufTokens (like pufWETH,
7
- * pufstETH, pufwstETH etc.).
13
+ * Handler for the `BoringVault` contract for a given token exposing
14
+ * methods to interact with the contract.
8
15
  */
9
- export declare class PufTokenHandler {
16
+ export declare class NucleusBoringVaultHandler {
10
17
  private chain;
11
18
  private walletClient;
12
19
  private publicClient;
13
20
  private viemChain;
14
- private pufToken;
15
21
  /**
16
- * Create the handler for the `PufToken` contract exposing methods to
17
- * interact with the contract.
22
+ * Create the handler for processing UniFi tokens.
18
23
  *
19
24
  * @param chain Chain to use for the client.
20
25
  * @param walletClient The wallet client to use for wallet
@@ -23,13 +28,6 @@ export declare class PufTokenHandler {
23
28
  * interactions.
24
29
  */
25
30
  constructor(chain: Chain, walletClient: WalletClient, publicClient: PublicClient);
26
- /**
27
- * Set the PufToken to use for executing transactions on the contract.
28
- *
29
- * @param pufToken The PufToken to use for the handler.
30
- * @returns The handler.
31
- */
32
- withPufToken(pufToken: PufToken): this;
33
31
  /**
34
32
  * Get the contract. This is a method because the typings are complex
35
33
  * and lost when trying to make it a member.
@@ -37,680 +35,626 @@ export declare class PufTokenHandler {
37
35
  * @returns The viem contract.
38
36
  */
39
37
  getContract(): GetContractReturnType<readonly [{
40
- readonly type: "constructor";
41
38
  readonly inputs: readonly [{
42
- readonly name: "token";
43
- readonly type: "address";
44
39
  readonly internalType: "address";
40
+ readonly name: "_owner";
41
+ readonly type: "address";
45
42
  }, {
46
- readonly name: "tokenName";
47
- readonly type: "string";
48
43
  readonly internalType: "string";
49
- }, {
50
- readonly name: "tokenSymbol";
44
+ readonly name: "_name";
51
45
  readonly type: "string";
46
+ }, {
52
47
  readonly internalType: "string";
48
+ readonly name: "_symbol";
49
+ readonly type: "string";
53
50
  }, {
54
- readonly name: "depositCap";
55
- readonly type: "uint256";
56
- readonly internalType: "uint256";
51
+ readonly internalType: "uint8";
52
+ readonly name: "_decimals";
53
+ readonly type: "uint8";
57
54
  }];
58
55
  readonly stateMutability: "nonpayable";
56
+ readonly type: "constructor";
59
57
  }, {
60
- readonly type: "function";
61
- readonly name: "DOMAIN_SEPARATOR";
62
- readonly inputs: readonly [];
63
- readonly outputs: readonly [{
64
- readonly name: "";
65
- readonly type: "bytes32";
66
- readonly internalType: "bytes32";
67
- }];
68
- readonly stateMutability: "view";
69
- }, {
70
- readonly type: "function";
71
- readonly name: "PUFFER_FACTORY";
72
- readonly inputs: readonly [];
73
- readonly outputs: readonly [{
74
- readonly name: "";
58
+ readonly inputs: readonly [{
59
+ readonly internalType: "address";
60
+ readonly name: "target";
75
61
  readonly type: "address";
76
- readonly internalType: "contract PufferL2Depositor";
77
62
  }];
78
- readonly stateMutability: "view";
63
+ readonly name: "AddressEmptyCode";
64
+ readonly type: "error";
79
65
  }, {
80
- readonly type: "function";
81
- readonly name: "TOKEN";
82
66
  readonly inputs: readonly [];
83
- readonly outputs: readonly [{
84
- readonly name: "";
85
- readonly type: "address";
86
- readonly internalType: "contract ERC20";
87
- }];
88
- readonly stateMutability: "view";
67
+ readonly name: "FailedCall";
68
+ readonly type: "error";
89
69
  }, {
90
- readonly type: "function";
91
- readonly name: "allowance";
92
70
  readonly inputs: readonly [{
93
- readonly name: "owner";
94
- readonly type: "address";
95
- readonly internalType: "address";
96
- }, {
97
- readonly name: "spender";
98
- readonly type: "address";
99
- readonly internalType: "address";
100
- }];
101
- readonly outputs: readonly [{
102
- readonly name: "";
71
+ readonly internalType: "uint256";
72
+ readonly name: "balance";
103
73
  readonly type: "uint256";
74
+ }, {
104
75
  readonly internalType: "uint256";
76
+ readonly name: "needed";
77
+ readonly type: "uint256";
105
78
  }];
106
- readonly stateMutability: "view";
79
+ readonly name: "InsufficientBalance";
80
+ readonly type: "error";
107
81
  }, {
108
- readonly type: "function";
109
- readonly name: "approve";
82
+ readonly anonymous: false;
110
83
  readonly inputs: readonly [{
111
- readonly name: "spender";
84
+ readonly indexed: true;
85
+ readonly internalType: "address";
86
+ readonly name: "owner";
112
87
  readonly type: "address";
88
+ }, {
89
+ readonly indexed: true;
113
90
  readonly internalType: "address";
91
+ readonly name: "spender";
92
+ readonly type: "address";
114
93
  }, {
115
- readonly name: "value";
116
- readonly type: "uint256";
94
+ readonly indexed: false;
117
95
  readonly internalType: "uint256";
96
+ readonly name: "amount";
97
+ readonly type: "uint256";
118
98
  }];
119
- readonly outputs: readonly [{
120
- readonly name: "";
121
- readonly type: "bool";
122
- readonly internalType: "bool";
123
- }];
124
- readonly stateMutability: "nonpayable";
99
+ readonly name: "Approval";
100
+ readonly type: "event";
125
101
  }, {
126
- readonly type: "function";
127
- readonly name: "balanceOf";
102
+ readonly anonymous: false;
128
103
  readonly inputs: readonly [{
129
- readonly name: "account";
130
- readonly type: "address";
104
+ readonly indexed: true;
131
105
  readonly internalType: "address";
106
+ readonly name: "user";
107
+ readonly type: "address";
108
+ }, {
109
+ readonly indexed: true;
110
+ readonly internalType: "contract Authority";
111
+ readonly name: "newAuthority";
112
+ readonly type: "address";
132
113
  }];
133
- readonly outputs: readonly [{
134
- readonly name: "";
135
- readonly type: "uint256";
136
- readonly internalType: "uint256";
137
- }];
138
- readonly stateMutability: "view";
139
- }, {
140
- readonly type: "function";
141
- readonly name: "decimals";
142
- readonly inputs: readonly [];
143
- readonly outputs: readonly [{
144
- readonly name: "";
145
- readonly type: "uint8";
146
- readonly internalType: "uint8";
147
- }];
148
- readonly stateMutability: "view";
114
+ readonly name: "AuthorityUpdated";
115
+ readonly type: "event";
149
116
  }, {
150
- readonly type: "function";
151
- readonly name: "deposit";
117
+ readonly anonymous: false;
152
118
  readonly inputs: readonly [{
119
+ readonly indexed: true;
120
+ readonly internalType: "address";
153
121
  readonly name: "from";
154
122
  readonly type: "address";
155
- readonly internalType: "address";
156
123
  }, {
157
- readonly name: "account";
158
- readonly type: "address";
124
+ readonly indexed: true;
159
125
  readonly internalType: "address";
126
+ readonly name: "asset";
127
+ readonly type: "address";
160
128
  }, {
129
+ readonly indexed: false;
130
+ readonly internalType: "uint256";
161
131
  readonly name: "amount";
162
132
  readonly type: "uint256";
133
+ }, {
134
+ readonly indexed: true;
135
+ readonly internalType: "address";
136
+ readonly name: "to";
137
+ readonly type: "address";
138
+ }, {
139
+ readonly indexed: false;
163
140
  readonly internalType: "uint256";
141
+ readonly name: "shares";
142
+ readonly type: "uint256";
164
143
  }];
165
- readonly outputs: readonly [];
166
- readonly stateMutability: "nonpayable";
144
+ readonly name: "Enter";
145
+ readonly type: "event";
167
146
  }, {
168
- readonly type: "function";
169
- readonly name: "eip712Domain";
170
- readonly inputs: readonly [];
171
- readonly outputs: readonly [{
172
- readonly name: "fields";
173
- readonly type: "bytes1";
174
- readonly internalType: "bytes1";
175
- }, {
176
- readonly name: "name";
177
- readonly type: "string";
178
- readonly internalType: "string";
147
+ readonly anonymous: false;
148
+ readonly inputs: readonly [{
149
+ readonly indexed: true;
150
+ readonly internalType: "address";
151
+ readonly name: "to";
152
+ readonly type: "address";
179
153
  }, {
180
- readonly name: "version";
181
- readonly type: "string";
182
- readonly internalType: "string";
154
+ readonly indexed: true;
155
+ readonly internalType: "address";
156
+ readonly name: "asset";
157
+ readonly type: "address";
183
158
  }, {
184
- readonly name: "chainId";
185
- readonly type: "uint256";
159
+ readonly indexed: false;
186
160
  readonly internalType: "uint256";
161
+ readonly name: "amount";
162
+ readonly type: "uint256";
187
163
  }, {
188
- readonly name: "verifyingContract";
189
- readonly type: "address";
164
+ readonly indexed: true;
190
165
  readonly internalType: "address";
166
+ readonly name: "from";
167
+ readonly type: "address";
191
168
  }, {
192
- readonly name: "salt";
193
- readonly type: "bytes32";
194
- readonly internalType: "bytes32";
195
- }, {
196
- readonly name: "extensions";
197
- readonly type: "uint256[]";
198
- readonly internalType: "uint256[]";
169
+ readonly indexed: false;
170
+ readonly internalType: "uint256";
171
+ readonly name: "shares";
172
+ readonly type: "uint256";
199
173
  }];
200
- readonly stateMutability: "view";
174
+ readonly name: "Exit";
175
+ readonly type: "event";
201
176
  }, {
202
- readonly type: "function";
203
- readonly name: "migrate";
177
+ readonly anonymous: false;
204
178
  readonly inputs: readonly [{
205
- readonly name: "amount";
206
- readonly type: "uint256";
207
- readonly internalType: "uint256";
208
- }, {
209
- readonly name: "migratorContract";
210
- readonly type: "address";
179
+ readonly indexed: true;
211
180
  readonly internalType: "address";
212
- }, {
213
- readonly name: "destination";
181
+ readonly name: "user";
214
182
  readonly type: "address";
183
+ }, {
184
+ readonly indexed: true;
215
185
  readonly internalType: "address";
186
+ readonly name: "newOwner";
187
+ readonly type: "address";
216
188
  }];
217
- readonly outputs: readonly [];
218
- readonly stateMutability: "nonpayable";
189
+ readonly name: "OwnershipTransferred";
190
+ readonly type: "event";
219
191
  }, {
220
- readonly type: "function";
221
- readonly name: "migrateWithSignature";
192
+ readonly anonymous: false;
222
193
  readonly inputs: readonly [{
223
- readonly name: "depositor";
224
- readonly type: "address";
194
+ readonly indexed: true;
225
195
  readonly internalType: "address";
226
- }, {
227
- readonly name: "migratorContract";
196
+ readonly name: "from";
228
197
  readonly type: "address";
229
- readonly internalType: "address";
230
198
  }, {
231
- readonly name: "destination";
232
- readonly type: "address";
199
+ readonly indexed: true;
233
200
  readonly internalType: "address";
201
+ readonly name: "to";
202
+ readonly type: "address";
234
203
  }, {
235
- readonly name: "amount";
236
- readonly type: "uint256";
204
+ readonly indexed: false;
237
205
  readonly internalType: "uint256";
238
- }, {
239
- readonly name: "signatureExpiry";
206
+ readonly name: "amount";
240
207
  readonly type: "uint256";
241
- readonly internalType: "uint256";
242
- }, {
243
- readonly name: "stakerSignature";
244
- readonly type: "bytes";
245
- readonly internalType: "bytes";
246
208
  }];
247
- readonly outputs: readonly [];
248
- readonly stateMutability: "nonpayable";
209
+ readonly name: "Transfer";
210
+ readonly type: "event";
249
211
  }, {
250
- readonly type: "function";
251
- readonly name: "name";
252
212
  readonly inputs: readonly [];
213
+ readonly name: "DOMAIN_SEPARATOR";
253
214
  readonly outputs: readonly [{
215
+ readonly internalType: "bytes32";
254
216
  readonly name: "";
255
- readonly type: "string";
256
- readonly internalType: "string";
217
+ readonly type: "bytes32";
257
218
  }];
258
219
  readonly stateMutability: "view";
259
- }, {
260
220
  readonly type: "function";
261
- readonly name: "nonces";
221
+ }, {
262
222
  readonly inputs: readonly [{
263
- readonly name: "owner";
223
+ readonly internalType: "address";
224
+ readonly name: "";
264
225
  readonly type: "address";
226
+ }, {
265
227
  readonly internalType: "address";
228
+ readonly name: "";
229
+ readonly type: "address";
266
230
  }];
231
+ readonly name: "allowance";
267
232
  readonly outputs: readonly [{
233
+ readonly internalType: "uint256";
268
234
  readonly name: "";
269
235
  readonly type: "uint256";
270
- readonly internalType: "uint256";
271
236
  }];
272
237
  readonly stateMutability: "view";
273
- }, {
274
238
  readonly type: "function";
275
- readonly name: "permit";
239
+ }, {
276
240
  readonly inputs: readonly [{
277
- readonly name: "owner";
278
- readonly type: "address";
279
241
  readonly internalType: "address";
280
- }, {
281
242
  readonly name: "spender";
282
243
  readonly type: "address";
283
- readonly internalType: "address";
284
244
  }, {
285
- readonly name: "value";
286
- readonly type: "uint256";
287
245
  readonly internalType: "uint256";
288
- }, {
289
- readonly name: "deadline";
246
+ readonly name: "amount";
290
247
  readonly type: "uint256";
291
- readonly internalType: "uint256";
292
- }, {
293
- readonly name: "v";
294
- readonly type: "uint8";
295
- readonly internalType: "uint8";
296
- }, {
297
- readonly name: "r";
298
- readonly type: "bytes32";
299
- readonly internalType: "bytes32";
300
- }, {
301
- readonly name: "s";
302
- readonly type: "bytes32";
303
- readonly internalType: "bytes32";
304
248
  }];
305
- readonly outputs: readonly [];
306
- readonly stateMutability: "nonpayable";
307
- }, {
308
- readonly type: "function";
309
- readonly name: "setDepositCap";
310
- readonly inputs: readonly [{
311
- readonly name: "newDepositCap";
312
- readonly type: "uint256";
313
- readonly internalType: "uint256";
249
+ readonly name: "approve";
250
+ readonly outputs: readonly [{
251
+ readonly internalType: "bool";
252
+ readonly name: "";
253
+ readonly type: "bool";
314
254
  }];
315
- readonly outputs: readonly [];
316
255
  readonly stateMutability: "nonpayable";
317
- }, {
318
256
  readonly type: "function";
319
- readonly name: "symbol";
257
+ }, {
320
258
  readonly inputs: readonly [];
259
+ readonly name: "authority";
321
260
  readonly outputs: readonly [{
261
+ readonly internalType: "contract Authority";
322
262
  readonly name: "";
323
- readonly type: "string";
324
- readonly internalType: "string";
263
+ readonly type: "address";
325
264
  }];
326
265
  readonly stateMutability: "view";
327
- }, {
328
266
  readonly type: "function";
329
- readonly name: "totalDepositCap";
330
- readonly inputs: readonly [];
267
+ }, {
268
+ readonly inputs: readonly [{
269
+ readonly internalType: "address";
270
+ readonly name: "";
271
+ readonly type: "address";
272
+ }];
273
+ readonly name: "balanceOf";
331
274
  readonly outputs: readonly [{
275
+ readonly internalType: "uint256";
332
276
  readonly name: "";
333
277
  readonly type: "uint256";
334
- readonly internalType: "uint256";
335
278
  }];
336
279
  readonly stateMutability: "view";
337
- }, {
338
280
  readonly type: "function";
339
- readonly name: "totalSupply";
281
+ }, {
340
282
  readonly inputs: readonly [];
283
+ readonly name: "decimals";
341
284
  readonly outputs: readonly [{
285
+ readonly internalType: "uint8";
342
286
  readonly name: "";
343
- readonly type: "uint256";
344
- readonly internalType: "uint256";
287
+ readonly type: "uint8";
345
288
  }];
346
289
  readonly stateMutability: "view";
347
- }, {
348
290
  readonly type: "function";
349
- readonly name: "transfer";
350
- readonly inputs: readonly [{
351
- readonly name: "to";
352
- readonly type: "address";
353
- readonly internalType: "address";
354
- }, {
355
- readonly name: "value";
356
- readonly type: "uint256";
357
- readonly internalType: "uint256";
358
- }];
359
- readonly outputs: readonly [{
360
- readonly name: "";
361
- readonly type: "bool";
362
- readonly internalType: "bool";
363
- }];
364
- readonly stateMutability: "nonpayable";
365
291
  }, {
366
- readonly type: "function";
367
- readonly name: "transferFrom";
368
292
  readonly inputs: readonly [{
293
+ readonly internalType: "address";
369
294
  readonly name: "from";
370
295
  readonly type: "address";
371
- readonly internalType: "address";
372
296
  }, {
373
- readonly name: "to";
297
+ readonly internalType: "contract ERC20";
298
+ readonly name: "asset";
374
299
  readonly type: "address";
375
- readonly internalType: "address";
376
300
  }, {
377
- readonly name: "value";
378
- readonly type: "uint256";
379
301
  readonly internalType: "uint256";
380
- }];
381
- readonly outputs: readonly [{
382
- readonly name: "";
383
- readonly type: "bool";
384
- readonly internalType: "bool";
385
- }];
386
- readonly stateMutability: "nonpayable";
387
- }, {
388
- readonly type: "function";
389
- readonly name: "withdraw";
390
- readonly inputs: readonly [{
391
- readonly name: "recipient";
392
- readonly type: "address";
302
+ readonly name: "assetAmount";
303
+ readonly type: "uint256";
304
+ }, {
393
305
  readonly internalType: "address";
306
+ readonly name: "to";
307
+ readonly type: "address";
394
308
  }, {
395
- readonly name: "amount";
396
- readonly type: "uint256";
397
309
  readonly internalType: "uint256";
310
+ readonly name: "shareAmount";
311
+ readonly type: "uint256";
398
312
  }];
313
+ readonly name: "enter";
399
314
  readonly outputs: readonly [];
400
315
  readonly stateMutability: "nonpayable";
316
+ readonly type: "function";
401
317
  }, {
402
- readonly type: "event";
403
- readonly name: "Approval";
404
318
  readonly inputs: readonly [{
405
- readonly name: "owner";
406
- readonly type: "address";
407
- readonly indexed: true;
408
319
  readonly internalType: "address";
320
+ readonly name: "to";
321
+ readonly type: "address";
409
322
  }, {
410
- readonly name: "spender";
323
+ readonly internalType: "contract ERC20";
324
+ readonly name: "asset";
411
325
  readonly type: "address";
412
- readonly indexed: true;
413
- readonly internalType: "address";
414
326
  }, {
415
- readonly name: "value";
416
- readonly type: "uint256";
417
- readonly indexed: false;
418
327
  readonly internalType: "uint256";
419
- }];
420
- readonly anonymous: false;
421
- }, {
422
- readonly type: "event";
423
- readonly name: "DepositCapChanged";
424
- readonly inputs: readonly [{
425
- readonly name: "oldDepositCap";
328
+ readonly name: "assetAmount";
426
329
  readonly type: "uint256";
427
- readonly indexed: false;
428
- readonly internalType: "uint256";
429
330
  }, {
430
- readonly name: "newDepositCap";
431
- readonly type: "uint256";
432
- readonly indexed: false;
433
- readonly internalType: "uint256";
434
- }];
435
- readonly anonymous: false;
436
- }, {
437
- readonly type: "event";
438
- readonly name: "Deposited";
439
- readonly inputs: readonly [{
440
- readonly name: "from";
441
- readonly type: "address";
442
- readonly indexed: true;
443
331
  readonly internalType: "address";
444
- }, {
445
- readonly name: "to";
332
+ readonly name: "from";
446
333
  readonly type: "address";
447
- readonly indexed: true;
448
- readonly internalType: "address";
449
334
  }, {
450
- readonly name: "amount";
451
- readonly type: "uint256";
452
- readonly indexed: false;
453
335
  readonly internalType: "uint256";
336
+ readonly name: "shareAmount";
337
+ readonly type: "uint256";
454
338
  }];
455
- readonly anonymous: false;
339
+ readonly name: "exit";
340
+ readonly outputs: readonly [];
341
+ readonly stateMutability: "nonpayable";
342
+ readonly type: "function";
456
343
  }, {
457
- readonly type: "event";
458
- readonly name: "EIP712DomainChanged";
459
344
  readonly inputs: readonly [];
460
- readonly anonymous: false;
461
- }, {
462
- readonly type: "event";
463
- readonly name: "Migrated";
464
- readonly inputs: readonly [{
465
- readonly name: "depositor";
466
- readonly type: "address";
467
- readonly indexed: true;
468
- readonly internalType: "address";
469
- }, {
470
- readonly name: "destination";
471
- readonly type: "address";
472
- readonly indexed: true;
473
- readonly internalType: "address";
474
- }, {
475
- readonly name: "migratorContract";
345
+ readonly name: "hook";
346
+ readonly outputs: readonly [{
347
+ readonly internalType: "contract BeforeTransferHook";
348
+ readonly name: "";
476
349
  readonly type: "address";
477
- readonly indexed: true;
478
- readonly internalType: "address";
479
- }, {
480
- readonly name: "amount";
481
- readonly type: "uint256";
482
- readonly indexed: false;
483
- readonly internalType: "uint256";
484
350
  }];
485
- readonly anonymous: false;
351
+ readonly stateMutability: "view";
352
+ readonly type: "function";
486
353
  }, {
487
- readonly type: "event";
488
- readonly name: "Transfer";
489
354
  readonly inputs: readonly [{
490
- readonly name: "from";
491
- readonly type: "address";
492
- readonly indexed: true;
493
- readonly internalType: "address";
355
+ readonly internalType: "address[]";
356
+ readonly name: "targets";
357
+ readonly type: "address[]";
494
358
  }, {
495
- readonly name: "to";
496
- readonly type: "address";
497
- readonly indexed: true;
498
- readonly internalType: "address";
359
+ readonly internalType: "bytes[]";
360
+ readonly name: "data";
361
+ readonly type: "bytes[]";
499
362
  }, {
500
- readonly name: "value";
501
- readonly type: "uint256";
502
- readonly indexed: false;
503
- readonly internalType: "uint256";
363
+ readonly internalType: "uint256[]";
364
+ readonly name: "values";
365
+ readonly type: "uint256[]";
504
366
  }];
505
- readonly anonymous: false;
367
+ readonly name: "manage";
368
+ readonly outputs: readonly [{
369
+ readonly internalType: "bytes[]";
370
+ readonly name: "results";
371
+ readonly type: "bytes[]";
372
+ }];
373
+ readonly stateMutability: "nonpayable";
374
+ readonly type: "function";
506
375
  }, {
507
- readonly type: "event";
508
- readonly name: "Withdrawn";
509
376
  readonly inputs: readonly [{
510
- readonly name: "from";
511
- readonly type: "address";
512
- readonly indexed: true;
513
377
  readonly internalType: "address";
514
- }, {
515
- readonly name: "to";
378
+ readonly name: "target";
516
379
  readonly type: "address";
517
- readonly indexed: true;
518
- readonly internalType: "address";
519
380
  }, {
520
- readonly name: "amount";
521
- readonly type: "uint256";
522
- readonly indexed: false;
381
+ readonly internalType: "bytes";
382
+ readonly name: "data";
383
+ readonly type: "bytes";
384
+ }, {
523
385
  readonly internalType: "uint256";
386
+ readonly name: "value";
387
+ readonly type: "uint256";
524
388
  }];
525
- readonly anonymous: false;
526
- }, {
527
- readonly type: "error";
528
- readonly name: "AddressEmptyCode";
529
- readonly inputs: readonly [{
530
- readonly name: "target";
531
- readonly type: "address";
532
- readonly internalType: "address";
533
- }];
534
- }, {
535
- readonly type: "error";
536
- readonly name: "AddressInsufficientBalance";
537
- readonly inputs: readonly [{
538
- readonly name: "account";
539
- readonly type: "address";
540
- readonly internalType: "address";
389
+ readonly name: "manage";
390
+ readonly outputs: readonly [{
391
+ readonly internalType: "bytes";
392
+ readonly name: "result";
393
+ readonly type: "bytes";
541
394
  }];
395
+ readonly stateMutability: "nonpayable";
396
+ readonly type: "function";
542
397
  }, {
543
- readonly type: "error";
544
- readonly name: "ECDSAInvalidSignature";
545
398
  readonly inputs: readonly [];
546
- }, {
547
- readonly type: "error";
548
- readonly name: "ECDSAInvalidSignatureLength";
549
- readonly inputs: readonly [{
550
- readonly name: "length";
551
- readonly type: "uint256";
552
- readonly internalType: "uint256";
399
+ readonly name: "name";
400
+ readonly outputs: readonly [{
401
+ readonly internalType: "string";
402
+ readonly name: "";
403
+ readonly type: "string";
553
404
  }];
405
+ readonly stateMutability: "view";
406
+ readonly type: "function";
554
407
  }, {
555
- readonly type: "error";
556
- readonly name: "ECDSAInvalidSignatureS";
557
408
  readonly inputs: readonly [{
558
- readonly name: "s";
559
- readonly type: "bytes32";
560
- readonly internalType: "bytes32";
409
+ readonly internalType: "address";
410
+ readonly name: "";
411
+ readonly type: "address";
561
412
  }];
413
+ readonly name: "nonces";
414
+ readonly outputs: readonly [{
415
+ readonly internalType: "uint256";
416
+ readonly name: "";
417
+ readonly type: "uint256";
418
+ }];
419
+ readonly stateMutability: "view";
420
+ readonly type: "function";
562
421
  }, {
563
- readonly type: "error";
564
- readonly name: "ERC20InsufficientAllowance";
565
422
  readonly inputs: readonly [{
566
- readonly name: "spender";
423
+ readonly internalType: "address";
424
+ readonly name: "";
567
425
  readonly type: "address";
426
+ }, {
568
427
  readonly internalType: "address";
428
+ readonly name: "";
429
+ readonly type: "address";
569
430
  }, {
570
- readonly name: "allowance";
571
- readonly type: "uint256";
572
- readonly internalType: "uint256";
431
+ readonly internalType: "uint256[]";
432
+ readonly name: "";
433
+ readonly type: "uint256[]";
573
434
  }, {
574
- readonly name: "needed";
575
- readonly type: "uint256";
576
- readonly internalType: "uint256";
435
+ readonly internalType: "uint256[]";
436
+ readonly name: "";
437
+ readonly type: "uint256[]";
438
+ }, {
439
+ readonly internalType: "bytes";
440
+ readonly name: "";
441
+ readonly type: "bytes";
442
+ }];
443
+ readonly name: "onERC1155BatchReceived";
444
+ readonly outputs: readonly [{
445
+ readonly internalType: "bytes4";
446
+ readonly name: "";
447
+ readonly type: "bytes4";
577
448
  }];
449
+ readonly stateMutability: "nonpayable";
450
+ readonly type: "function";
578
451
  }, {
579
- readonly type: "error";
580
- readonly name: "ERC20InsufficientBalance";
581
452
  readonly inputs: readonly [{
582
- readonly name: "sender";
453
+ readonly internalType: "address";
454
+ readonly name: "";
583
455
  readonly type: "address";
456
+ }, {
584
457
  readonly internalType: "address";
458
+ readonly name: "";
459
+ readonly type: "address";
585
460
  }, {
586
- readonly name: "balance";
587
- readonly type: "uint256";
588
461
  readonly internalType: "uint256";
589
- }, {
590
- readonly name: "needed";
462
+ readonly name: "";
591
463
  readonly type: "uint256";
464
+ }, {
592
465
  readonly internalType: "uint256";
466
+ readonly name: "";
467
+ readonly type: "uint256";
468
+ }, {
469
+ readonly internalType: "bytes";
470
+ readonly name: "";
471
+ readonly type: "bytes";
472
+ }];
473
+ readonly name: "onERC1155Received";
474
+ readonly outputs: readonly [{
475
+ readonly internalType: "bytes4";
476
+ readonly name: "";
477
+ readonly type: "bytes4";
593
478
  }];
479
+ readonly stateMutability: "nonpayable";
480
+ readonly type: "function";
594
481
  }, {
595
- readonly type: "error";
596
- readonly name: "ERC20InvalidApprover";
597
482
  readonly inputs: readonly [{
598
- readonly name: "approver";
483
+ readonly internalType: "address";
484
+ readonly name: "";
599
485
  readonly type: "address";
486
+ }, {
600
487
  readonly internalType: "address";
488
+ readonly name: "";
489
+ readonly type: "address";
490
+ }, {
491
+ readonly internalType: "uint256";
492
+ readonly name: "";
493
+ readonly type: "uint256";
494
+ }, {
495
+ readonly internalType: "bytes";
496
+ readonly name: "";
497
+ readonly type: "bytes";
601
498
  }];
499
+ readonly name: "onERC721Received";
500
+ readonly outputs: readonly [{
501
+ readonly internalType: "bytes4";
502
+ readonly name: "";
503
+ readonly type: "bytes4";
504
+ }];
505
+ readonly stateMutability: "nonpayable";
506
+ readonly type: "function";
602
507
  }, {
603
- readonly type: "error";
604
- readonly name: "ERC20InvalidReceiver";
605
- readonly inputs: readonly [{
606
- readonly name: "receiver";
607
- readonly type: "address";
508
+ readonly inputs: readonly [];
509
+ readonly name: "owner";
510
+ readonly outputs: readonly [{
608
511
  readonly internalType: "address";
512
+ readonly name: "";
513
+ readonly type: "address";
609
514
  }];
515
+ readonly stateMutability: "view";
516
+ readonly type: "function";
610
517
  }, {
611
- readonly type: "error";
612
- readonly name: "ERC20InvalidSender";
613
518
  readonly inputs: readonly [{
614
- readonly name: "sender";
519
+ readonly internalType: "address";
520
+ readonly name: "owner";
615
521
  readonly type: "address";
522
+ }, {
616
523
  readonly internalType: "address";
617
- }];
618
- }, {
619
- readonly type: "error";
620
- readonly name: "ERC20InvalidSpender";
621
- readonly inputs: readonly [{
622
524
  readonly name: "spender";
623
525
  readonly type: "address";
624
- readonly internalType: "address";
625
- }];
626
- }, {
627
- readonly type: "error";
628
- readonly name: "ERC2612ExpiredSignature";
629
- readonly inputs: readonly [{
630
- readonly name: "deadline";
526
+ }, {
527
+ readonly internalType: "uint256";
528
+ readonly name: "value";
631
529
  readonly type: "uint256";
530
+ }, {
632
531
  readonly internalType: "uint256";
532
+ readonly name: "deadline";
533
+ readonly type: "uint256";
534
+ }, {
535
+ readonly internalType: "uint8";
536
+ readonly name: "v";
537
+ readonly type: "uint8";
538
+ }, {
539
+ readonly internalType: "bytes32";
540
+ readonly name: "r";
541
+ readonly type: "bytes32";
542
+ }, {
543
+ readonly internalType: "bytes32";
544
+ readonly name: "s";
545
+ readonly type: "bytes32";
633
546
  }];
547
+ readonly name: "permit";
548
+ readonly outputs: readonly [];
549
+ readonly stateMutability: "nonpayable";
550
+ readonly type: "function";
634
551
  }, {
635
- readonly type: "error";
636
- readonly name: "ERC2612InvalidSigner";
637
552
  readonly inputs: readonly [{
638
- readonly name: "signer";
553
+ readonly internalType: "contract Authority";
554
+ readonly name: "newAuthority";
639
555
  readonly type: "address";
556
+ }];
557
+ readonly name: "setAuthority";
558
+ readonly outputs: readonly [];
559
+ readonly stateMutability: "nonpayable";
560
+ readonly type: "function";
561
+ }, {
562
+ readonly inputs: readonly [{
640
563
  readonly internalType: "address";
641
- }, {
642
- readonly name: "owner";
564
+ readonly name: "_hook";
643
565
  readonly type: "address";
644
- readonly internalType: "address";
645
566
  }];
567
+ readonly name: "setBeforeTransferHook";
568
+ readonly outputs: readonly [];
569
+ readonly stateMutability: "nonpayable";
570
+ readonly type: "function";
646
571
  }, {
647
- readonly type: "error";
648
- readonly name: "ExpiredSignature";
649
- readonly inputs: readonly [];
572
+ readonly inputs: readonly [{
573
+ readonly internalType: "bytes4";
574
+ readonly name: "interfaceId";
575
+ readonly type: "bytes4";
576
+ }];
577
+ readonly name: "supportsInterface";
578
+ readonly outputs: readonly [{
579
+ readonly internalType: "bool";
580
+ readonly name: "";
581
+ readonly type: "bool";
582
+ }];
583
+ readonly stateMutability: "view";
584
+ readonly type: "function";
650
585
  }, {
651
- readonly type: "error";
652
- readonly name: "FailedInnerCall";
653
586
  readonly inputs: readonly [];
587
+ readonly name: "symbol";
588
+ readonly outputs: readonly [{
589
+ readonly internalType: "string";
590
+ readonly name: "";
591
+ readonly type: "string";
592
+ }];
593
+ readonly stateMutability: "view";
594
+ readonly type: "function";
654
595
  }, {
655
- readonly type: "error";
656
- readonly name: "InvalidAccount";
657
596
  readonly inputs: readonly [];
597
+ readonly name: "totalSupply";
598
+ readonly outputs: readonly [{
599
+ readonly internalType: "uint256";
600
+ readonly name: "";
601
+ readonly type: "uint256";
602
+ }];
603
+ readonly stateMutability: "view";
604
+ readonly type: "function";
658
605
  }, {
659
- readonly type: "error";
660
- readonly name: "InvalidAccountNonce";
661
606
  readonly inputs: readonly [{
662
- readonly name: "account";
663
- readonly type: "address";
664
607
  readonly internalType: "address";
608
+ readonly name: "to";
609
+ readonly type: "address";
665
610
  }, {
666
- readonly name: "currentNonce";
667
- readonly type: "uint256";
668
611
  readonly internalType: "uint256";
612
+ readonly name: "amount";
613
+ readonly type: "uint256";
669
614
  }];
670
- }, {
671
- readonly type: "error";
672
- readonly name: "InvalidAmount";
673
- readonly inputs: readonly [];
674
- }, {
675
- readonly type: "error";
676
- readonly name: "InvalidShortString";
677
- readonly inputs: readonly [];
678
- }, {
679
- readonly type: "error";
680
- readonly name: "InvalidSignature";
681
- readonly inputs: readonly [];
682
- }, {
683
- readonly type: "error";
684
- readonly name: "MigratorContractNotAllowed";
685
- readonly inputs: readonly [{
686
- readonly name: "migrator";
687
- readonly type: "address";
688
- readonly internalType: "address";
615
+ readonly name: "transfer";
616
+ readonly outputs: readonly [{
617
+ readonly internalType: "bool";
618
+ readonly name: "";
619
+ readonly type: "bool";
689
620
  }];
621
+ readonly stateMutability: "nonpayable";
622
+ readonly type: "function";
690
623
  }, {
691
- readonly type: "error";
692
- readonly name: "SafeERC20FailedOperation";
693
624
  readonly inputs: readonly [{
694
- readonly name: "token";
625
+ readonly internalType: "address";
626
+ readonly name: "from";
695
627
  readonly type: "address";
628
+ }, {
696
629
  readonly internalType: "address";
630
+ readonly name: "to";
631
+ readonly type: "address";
632
+ }, {
633
+ readonly internalType: "uint256";
634
+ readonly name: "amount";
635
+ readonly type: "uint256";
636
+ }];
637
+ readonly name: "transferFrom";
638
+ readonly outputs: readonly [{
639
+ readonly internalType: "bool";
640
+ readonly name: "";
641
+ readonly type: "bool";
697
642
  }];
643
+ readonly stateMutability: "nonpayable";
644
+ readonly type: "function";
698
645
  }, {
699
- readonly type: "error";
700
- readonly name: "StringTooLong";
701
646
  readonly inputs: readonly [{
702
- readonly name: "str";
703
- readonly type: "string";
704
- readonly internalType: "string";
647
+ readonly internalType: "address";
648
+ readonly name: "newOwner";
649
+ readonly type: "address";
705
650
  }];
651
+ readonly name: "transferOwnership";
652
+ readonly outputs: readonly [];
653
+ readonly stateMutability: "nonpayable";
654
+ readonly type: "function";
706
655
  }, {
707
- readonly type: "error";
708
- readonly name: "TotalDepositCapReached";
709
- readonly inputs: readonly [];
710
- }, {
711
- readonly type: "error";
712
- readonly name: "Unauthorized";
713
- readonly inputs: readonly [];
656
+ readonly stateMutability: "payable";
657
+ readonly type: "receive";
714
658
  }], {
715
659
  public: {
716
660
  account: undefined;
@@ -6828,93 +6772,94 @@ export declare class PufTokenHandler {
6828
6772
  };
6829
6773
  }, Address>;
6830
6774
  /**
6831
- * Check the wrapped token (PufToken) balance of the wallet.
6775
+ * Get the allowance for the given owner and spender.
6832
6776
  *
6833
- * @param walletAddress Wallet address to check the balance of.
6834
- * @returns The wrapped token's (PufToken) balance in wei.
6777
+ * @param owner Address of the owner.
6778
+ * @param spender Address of the spender.
6779
+ * @returns Allowance for the given owner and spender.
6835
6780
  */
6836
- balanceOf(walletAddress: Address): Promise<bigint>;
6781
+ getAllowance(owner: Address, spender: Address): Promise<bigint>;
6837
6782
  /**
6838
- * Get the allowance for the spender to spend the owner's tokens.
6783
+ * Get the total supply of the token.
6839
6784
  *
6840
- * @param ownerAddress Address of the owner.
6841
- * @param spenderAddress Address of the spender.
6842
- * @returns Allowance that can be used by the spender.
6785
+ * @returns Total supply of the token.
6843
6786
  */
6844
- getAllowance(ownerAddress: Address, spenderAddress: Address): Promise<bigint>;
6787
+ getTotalSupply(): Promise<bigint>;
6845
6788
  /**
6846
- * Get the total cap of the PufToken that can be deposited.
6789
+ * Check the token balance of the wallet.
6847
6790
  *
6848
- * @returns Total cap of the PufToken that can be deposited.
6791
+ * @param walletAddress Wallet address to check the balance of.
6792
+ * @returns Token balance in wei.
6849
6793
  */
6850
- getTotalDepositCap(): Promise<bigint>;
6794
+ balanceOf(walletAddress: Address): Promise<bigint>;
6851
6795
  /**
6852
- * Get the total supply of the PufToken.
6796
+ * Get the total supply of the token.
6853
6797
  *
6854
- * @returns Total supply of the PufToken.
6798
+ * @returns Total supply of the token.
6855
6799
  */
6856
- getTotalSupply(): Promise<bigint>;
6800
+ totalSupply(): Promise<bigint>;
6801
+ /**
6802
+ * Approve transaction for the spender to spend the owner's tokens.
6803
+ *
6804
+ * @param walletAddress Address of the caller of the transaction.
6805
+ * @param spenderAddress Address of the spender.
6806
+ * @param value Value to approve for the spender.
6807
+ * @returns Hash of the transaction.
6808
+ */
6809
+ approve(walletAddress: Address, spenderAddress: Address, value: bigint): Promise<`0x${string}`>;
6857
6810
  /**
6858
- * Withdraws the PufToken and returns the underlying token to the
6859
- * given wallet. This doesn't make the transaction but returns two
6860
- * methods namely `transact` and `estimate`.
6811
+ * Transfer tokens from the owner's wallet to the given address.
6861
6812
  *
6862
- * @param walletAddress Wallet address to withdraw the PufToken from.
6863
- * @param value Value of the withdrawal.
6813
+ * @param walletAddress Address of the owner's wallet.
6814
+ * @param toAddress Address to transfer the tokens to.
6815
+ * @param value Value to transfer.
6864
6816
  * @returns `transact: () => Promise<Address>` - Used to make the
6865
- * transaction.
6817
+ * transaction with the given value.
6866
6818
  *
6867
6819
  * `estimate: () => Promise<bigint>` - Gas estimate of the
6868
6820
  * transaction.
6869
6821
  */
6870
- withdraw(walletAddress: Address, value: bigint): {
6822
+ transfer(walletAddress: Address, toAddress: Address, value: bigint): {
6871
6823
  transact: () => Promise<`0x${string}`>;
6872
6824
  estimate: () => Promise<bigint>;
6873
6825
  };
6874
6826
  /**
6875
- * Deposits the underlying token in exchange for the wrapped PufToken.
6876
- * This doesn't make the transaction but returns two methods namely
6877
- * `transact` and `estimate`.
6827
+ * Transfer tokens from the given address to another address.
6878
6828
  *
6879
- * @param depositorAddress Depositor of the underlying token.
6880
- * @param walletAddress Wallet address of the recipient of the
6881
- * deposit.
6882
- * @param value Value of the deposit.
6883
- * @returns `transact: () => Promise<Address>` - Used to make the
6884
- * transaction.
6829
+ * @param walletAddress Address of the caller of the transaction.
6830
+ * @param fromAddress Address to transfer the tokens from.
6831
+ * @param toAddress Address to transfer the tokens to.
6832
+ * @param value Value to transfer.
6833
+ * @returns `transact: () => Promise<Address>` - Used to
6834
+ * make the transaction with the given value.
6885
6835
  *
6886
6836
  * `estimate: () => Promise<bigint>` - Gas estimate of the
6887
6837
  * transaction.
6888
6838
  */
6889
- deposit(depositorAddress: Address, walletAddress: Address, value: bigint): {
6839
+ transferFrom(walletAddress: Address, fromAddress: Address, toAddress: Address, value: bigint): {
6890
6840
  transact: () => Promise<`0x${string}`>;
6891
6841
  estimate: () => Promise<bigint>;
6892
6842
  };
6893
6843
  /**
6894
- * Migrate tokens using an allowed `migratorContract` to the given
6895
- * wallet address. This doesn't make the transaction but returns two
6896
- * methods namely `transact` and `estimate`.
6844
+ * Get permit to be able to use the token.
6897
6845
  *
6898
- * @param walletAddress Address to migrate the tokens to.
6899
- * @param migratorContract Address of the migrator contract.
6900
- * @param value Value of the tokens to migrate.
6846
+ * @param walletAddress Address of the caller of the transaction.
6847
+ * @param params Permit parameters.
6848
+ * @param params.owner Address of the owner.
6849
+ * @param params.spender Address of the spender.
6850
+ * @param params.value Value to approve for the spender.
6851
+ * @param params.deadline Deadline for the permit.
6852
+ * @param params.v v value of the permit.
6853
+ * @param params.r r value of the permit.
6854
+ * @param params.s s value of the permit.
6901
6855
  * @returns `transact: () => Promise<Address>` - Used to make the
6902
- * transaction.
6856
+ * transaction with the given value.
6903
6857
  *
6904
6858
  * `estimate: () => Promise<bigint>` - Gas estimate of the
6905
6859
  * transaction.
6906
6860
  */
6907
- migrate(walletAddress: Address, migratorContract: Address, value: bigint): {
6861
+ permit(walletAddress: Address, params: PermitParams): {
6908
6862
  transact: () => Promise<`0x${string}`>;
6909
6863
  estimate: () => Promise<bigint>;
6910
6864
  };
6911
- /**
6912
- * Approve transaction for the spender to spend the owner's tokens.
6913
- *
6914
- * @param ownerAddress Address of the caller of the transaction.
6915
- * @param spenderAddress Address of the spender.
6916
- * @param value Value to approve for the spender.
6917
- * @returns Hash of the transaction.
6918
- */
6919
- approve(ownerAddress: Address, spenderAddress: Address, value: bigint): Promise<`0x${string}`>;
6920
6865
  }