@gitmyabi/usdt 1.0.6 → 1.0.8

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,2 +1,2 @@
1
- export { TetherUSDT_jsonAbi, TetherUSDT_json } from './TetherUSDT_json';
2
- export type { TetherUSDT_jsonAbi as TetherUSDT_jsonAbiType, TetherUSDT_jsonContract } from './TetherUSDT_json';
1
+ export { Tether_jsonAbi, Tether_json } from './Tether_json';
2
+ export type { Tether_jsonAbi as Tether_jsonAbiType, Tether_jsonContract } from './Tether_json';
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.TetherUSDT_json = exports.TetherUSDT_jsonAbi = void 0;
3
+ exports.Tether_json = exports.Tether_jsonAbi = void 0;
4
4
  // Auto-generated exports for all contracts
5
- var TetherUSDT_json_1 = require("./TetherUSDT_json");
6
- Object.defineProperty(exports, "TetherUSDT_jsonAbi", { enumerable: true, get: function () { return TetherUSDT_json_1.TetherUSDT_jsonAbi; } });
7
- Object.defineProperty(exports, "TetherUSDT_json", { enumerable: true, get: function () { return TetherUSDT_json_1.TetherUSDT_json; } });
5
+ var Tether_json_1 = require("./Tether_json");
6
+ Object.defineProperty(exports, "Tether_jsonAbi", { enumerable: true, get: function () { return Tether_json_1.Tether_jsonAbi; } });
7
+ Object.defineProperty(exports, "Tether_json", { enumerable: true, get: function () { return Tether_json_1.Tether_json; } });
@@ -1,3 +1,3 @@
1
1
  // Auto-generated exports for all contracts
2
- export { TetherUSDT_jsonAbi, TetherUSDT_json } from './TetherUSDT_json';
3
- export type { TetherUSDT_jsonAbi as TetherUSDT_jsonAbiType, TetherUSDT_jsonContract } from './TetherUSDT_json';
2
+ export { Tether_jsonAbi, Tether_json } from './Tether_json';
3
+ export type { Tether_jsonAbi as Tether_jsonAbiType, Tether_jsonContract } from './Tether_json';
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@gitmyabi/usdt",
3
- "version": "1.0.6",
4
- "description": "Auto-generated TypeScript type bindings for USDT (build etherscan-usdt-e7f88c1b-1785415611783, commit c53c47b, branch etherscan)",
3
+ "version": "1.0.8",
4
+ "description": "Auto-generated TypeScript type bindings for USDT (build etherscan-usdt-36bc33df-1785512519373, commit 3edf50f, branch etherscan)",
5
5
  "main": "./index.js",
6
6
  "types": "./index.d.ts",
7
7
  "exports": {
@@ -39,5 +39,5 @@
39
39
  "url": "https://github.com/etherscan/usdt"
40
40
  },
41
41
  "branch": "etherscan",
42
- "shortHash": "c53c47b"
42
+ "shortHash": "3edf50f"
43
43
  }
@@ -1,486 +0,0 @@
1
- import type { Address, PublicClient, WalletClient } from 'viem';
2
- /**
3
- * TetherUSDT_json ABI
4
- *
5
- * This ABI is typed using viem's type system for full type safety.
6
- */
7
- export declare const TetherUSDT_jsonAbi: readonly [{
8
- readonly inputs: readonly [];
9
- readonly stateMutability: "nonpayable";
10
- readonly type: "constructor";
11
- }, {
12
- readonly inputs: readonly [{
13
- readonly internalType: "address";
14
- readonly name: "spender";
15
- readonly type: "address";
16
- }, {
17
- readonly internalType: "uint256";
18
- readonly name: "allowance";
19
- readonly type: "uint256";
20
- }, {
21
- readonly internalType: "uint256";
22
- readonly name: "needed";
23
- readonly type: "uint256";
24
- }];
25
- readonly name: "ERC20InsufficientAllowance";
26
- readonly type: "error";
27
- }, {
28
- readonly inputs: readonly [{
29
- readonly internalType: "address";
30
- readonly name: "sender";
31
- readonly type: "address";
32
- }, {
33
- readonly internalType: "uint256";
34
- readonly name: "balance";
35
- readonly type: "uint256";
36
- }, {
37
- readonly internalType: "uint256";
38
- readonly name: "needed";
39
- readonly type: "uint256";
40
- }];
41
- readonly name: "ERC20InsufficientBalance";
42
- readonly type: "error";
43
- }, {
44
- readonly inputs: readonly [{
45
- readonly internalType: "address";
46
- readonly name: "approver";
47
- readonly type: "address";
48
- }];
49
- readonly name: "ERC20InvalidApprover";
50
- readonly type: "error";
51
- }, {
52
- readonly inputs: readonly [{
53
- readonly internalType: "address";
54
- readonly name: "receiver";
55
- readonly type: "address";
56
- }];
57
- readonly name: "ERC20InvalidReceiver";
58
- readonly type: "error";
59
- }, {
60
- readonly inputs: readonly [{
61
- readonly internalType: "address";
62
- readonly name: "sender";
63
- readonly type: "address";
64
- }];
65
- readonly name: "ERC20InvalidSender";
66
- readonly type: "error";
67
- }, {
68
- readonly inputs: readonly [{
69
- readonly internalType: "address";
70
- readonly name: "spender";
71
- readonly type: "address";
72
- }];
73
- readonly name: "ERC20InvalidSpender";
74
- readonly type: "error";
75
- }, {
76
- readonly anonymous: false;
77
- readonly inputs: readonly [{
78
- readonly indexed: true;
79
- readonly internalType: "address";
80
- readonly name: "owner";
81
- readonly type: "address";
82
- }, {
83
- readonly indexed: true;
84
- readonly internalType: "address";
85
- readonly name: "spender";
86
- readonly type: "address";
87
- }, {
88
- readonly indexed: false;
89
- readonly internalType: "uint256";
90
- readonly name: "value";
91
- readonly type: "uint256";
92
- }];
93
- readonly name: "Approval";
94
- readonly type: "event";
95
- }, {
96
- readonly anonymous: false;
97
- readonly inputs: readonly [{
98
- readonly indexed: true;
99
- readonly internalType: "address";
100
- readonly name: "from";
101
- readonly type: "address";
102
- }, {
103
- readonly indexed: true;
104
- readonly internalType: "address";
105
- readonly name: "to";
106
- readonly type: "address";
107
- }, {
108
- readonly indexed: false;
109
- readonly internalType: "uint256";
110
- readonly name: "value";
111
- readonly type: "uint256";
112
- }];
113
- readonly name: "Transfer";
114
- readonly type: "event";
115
- }, {
116
- readonly inputs: readonly [{
117
- readonly internalType: "address";
118
- readonly name: "owner";
119
- readonly type: "address";
120
- }, {
121
- readonly internalType: "address";
122
- readonly name: "spender";
123
- readonly type: "address";
124
- }];
125
- readonly name: "allowance";
126
- readonly outputs: readonly [{
127
- readonly internalType: "uint256";
128
- readonly name: "";
129
- readonly type: "uint256";
130
- }];
131
- readonly stateMutability: "view";
132
- readonly type: "function";
133
- }, {
134
- readonly inputs: readonly [{
135
- readonly internalType: "address";
136
- readonly name: "spender";
137
- readonly type: "address";
138
- }, {
139
- readonly internalType: "uint256";
140
- readonly name: "value";
141
- readonly type: "uint256";
142
- }];
143
- readonly name: "approve";
144
- readonly outputs: readonly [{
145
- readonly internalType: "bool";
146
- readonly name: "";
147
- readonly type: "bool";
148
- }];
149
- readonly stateMutability: "nonpayable";
150
- readonly type: "function";
151
- }, {
152
- readonly inputs: readonly [{
153
- readonly internalType: "address";
154
- readonly name: "account";
155
- readonly type: "address";
156
- }];
157
- readonly name: "balanceOf";
158
- readonly outputs: readonly [{
159
- readonly internalType: "uint256";
160
- readonly name: "";
161
- readonly type: "uint256";
162
- }];
163
- readonly stateMutability: "view";
164
- readonly type: "function";
165
- }, {
166
- readonly inputs: readonly [];
167
- readonly name: "decimals";
168
- readonly outputs: readonly [{
169
- readonly internalType: "uint8";
170
- readonly name: "";
171
- readonly type: "uint8";
172
- }];
173
- readonly stateMutability: "view";
174
- readonly type: "function";
175
- }, {
176
- readonly inputs: readonly [];
177
- readonly name: "name";
178
- readonly outputs: readonly [{
179
- readonly internalType: "string";
180
- readonly name: "";
181
- readonly type: "string";
182
- }];
183
- readonly stateMutability: "view";
184
- readonly type: "function";
185
- }, {
186
- readonly inputs: readonly [];
187
- readonly name: "symbol";
188
- readonly outputs: readonly [{
189
- readonly internalType: "string";
190
- readonly name: "";
191
- readonly type: "string";
192
- }];
193
- readonly stateMutability: "view";
194
- readonly type: "function";
195
- }, {
196
- readonly inputs: readonly [];
197
- readonly name: "totalSupply";
198
- readonly outputs: readonly [{
199
- readonly internalType: "uint256";
200
- readonly name: "";
201
- readonly type: "uint256";
202
- }];
203
- readonly stateMutability: "view";
204
- readonly type: "function";
205
- }, {
206
- readonly inputs: readonly [{
207
- readonly internalType: "address";
208
- readonly name: "to";
209
- readonly type: "address";
210
- }, {
211
- readonly internalType: "uint256";
212
- readonly name: "value";
213
- readonly type: "uint256";
214
- }];
215
- readonly name: "transfer";
216
- readonly outputs: readonly [{
217
- readonly internalType: "bool";
218
- readonly name: "";
219
- readonly type: "bool";
220
- }];
221
- readonly stateMutability: "nonpayable";
222
- readonly type: "function";
223
- }, {
224
- readonly inputs: readonly [{
225
- readonly internalType: "address";
226
- readonly name: "from";
227
- readonly type: "address";
228
- }, {
229
- readonly internalType: "address";
230
- readonly name: "to";
231
- readonly type: "address";
232
- }, {
233
- readonly internalType: "uint256";
234
- readonly name: "value";
235
- readonly type: "uint256";
236
- }];
237
- readonly name: "transferFrom";
238
- readonly outputs: readonly [{
239
- readonly internalType: "bool";
240
- readonly name: "";
241
- readonly type: "bool";
242
- }];
243
- readonly stateMutability: "nonpayable";
244
- readonly type: "function";
245
- }];
246
- /**
247
- * Type-safe ABI for TetherUSDT_json
248
- */
249
- export type TetherUSDT_jsonAbi = typeof TetherUSDT_jsonAbi;
250
- /**
251
- * Contract instance type for TetherUSDT_json
252
- */
253
- export type TetherUSDT_jsonContract = any;
254
- /**
255
- * TetherUSDT_json Contract Class
256
- *
257
- * Provides a class-based API similar to TypeChain for interacting with the contract.
258
- *
259
- * @example
260
- * ```typescript
261
- * import { createPublicClient, createWalletClient, http } from 'viem';
262
- * import { mainnet } from 'viem/chains';
263
- * import { TetherUSDT_json } from 'TetherUSDT_json';
264
- *
265
- * const publicClient = createPublicClient({ chain: mainnet, transport: http() });
266
- * const walletClient = createWalletClient({ chain: mainnet, transport: http() });
267
- *
268
- * const contract = new TetherUSDT_json('0x...', { publicClient, walletClient });
269
- *
270
- * // Read functions
271
- * const result = await contract.balanceOf('0x...');
272
- *
273
- * // Write functions
274
- * const hash = await contract.transfer('0x...', 1000n);
275
- *
276
- * // Simulate transactions (dry-run)
277
- * const simulation = await contract.simulate.transfer('0x...', 1000n);
278
- * console.log('Gas estimate:', simulation.request.gas);
279
- *
280
- * // Watch events
281
- * const unwatch = contract.watch.Transfer((event) => {
282
- * console.log('Transfer event:', event);
283
- * });
284
- * ```
285
- */
286
- export declare class TetherUSDT_json {
287
- private contract;
288
- private contractAddress;
289
- private publicClient;
290
- constructor(address: Address, clients: {
291
- publicClient: PublicClient;
292
- walletClient?: WalletClient;
293
- });
294
- /**
295
- * Get the contract address
296
- */
297
- get address(): Address;
298
- /**
299
- * Get the underlying viem contract instance
300
- */
301
- getContract(): TetherUSDT_jsonContract;
302
- /**
303
- * allowance
304
- * view
305
- */
306
- allowance(owner: `0x${string}`, spender: `0x${string}`): Promise<bigint>;
307
- /**
308
- * balanceOf
309
- * view
310
- */
311
- balanceOf(account: `0x${string}`): Promise<bigint>;
312
- /**
313
- * decimals
314
- * view
315
- */
316
- decimals(): Promise<bigint>;
317
- /**
318
- * name
319
- * view
320
- */
321
- name(): Promise<string>;
322
- /**
323
- * symbol
324
- * view
325
- */
326
- symbol(): Promise<string>;
327
- /**
328
- * totalSupply
329
- * view
330
- */
331
- totalSupply(): Promise<bigint>;
332
- /**
333
- * approve
334
- * nonpayable
335
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
336
- */
337
- approve(spender: `0x${string}`, value: bigint, options?: {
338
- accessList?: import('viem').AccessList;
339
- authorizationList?: import('viem').AuthorizationList;
340
- chain?: import('viem').Chain | null;
341
- dataSuffix?: `0x${string}`;
342
- gas?: bigint;
343
- gasPrice?: bigint;
344
- maxFeePerGas?: bigint;
345
- maxPriorityFeePerGas?: bigint;
346
- nonce?: number;
347
- value?: bigint;
348
- }): Promise<`0x${string}`>;
349
- /**
350
- * transfer
351
- * nonpayable
352
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
353
- */
354
- transfer(to: `0x${string}`, value: bigint, options?: {
355
- accessList?: import('viem').AccessList;
356
- authorizationList?: import('viem').AuthorizationList;
357
- chain?: import('viem').Chain | null;
358
- dataSuffix?: `0x${string}`;
359
- gas?: bigint;
360
- gasPrice?: bigint;
361
- maxFeePerGas?: bigint;
362
- maxPriorityFeePerGas?: bigint;
363
- nonce?: number;
364
- value?: bigint;
365
- }): Promise<`0x${string}`>;
366
- /**
367
- * transferFrom
368
- * nonpayable
369
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
370
- */
371
- transferFrom(from: `0x${string}`, to: `0x${string}`, value: bigint, options?: {
372
- accessList?: import('viem').AccessList;
373
- authorizationList?: import('viem').AuthorizationList;
374
- chain?: import('viem').Chain | null;
375
- dataSuffix?: `0x${string}`;
376
- gas?: bigint;
377
- gasPrice?: bigint;
378
- maxFeePerGas?: bigint;
379
- maxPriorityFeePerGas?: bigint;
380
- nonce?: number;
381
- value?: bigint;
382
- }): Promise<`0x${string}`>;
383
- /**
384
- * Simulate contract write operations (dry-run without sending transaction)
385
- *
386
- * @example
387
- * const result = await contract.simulate.transfer('0x...', 1000n);
388
- * console.log('Gas estimate:', result.request.gas);
389
- * console.log('Would succeed:', result.result);
390
- */
391
- get simulate(): {
392
- /**
393
- * Simulate approve
394
- * Returns gas estimate and result without sending transaction
395
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
396
- */
397
- approve(spender: `0x${string}`, value: bigint, options?: {
398
- accessList?: import("viem").AccessList;
399
- authorizationList?: import("viem").AuthorizationList;
400
- chain?: import("viem").Chain | null;
401
- dataSuffix?: `0x${string}`;
402
- gas?: bigint;
403
- gasPrice?: bigint;
404
- maxFeePerGas?: bigint;
405
- maxPriorityFeePerGas?: bigint;
406
- nonce?: number;
407
- value?: bigint;
408
- }): Promise<boolean>;
409
- /**
410
- * Simulate transfer
411
- * Returns gas estimate and result without sending transaction
412
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
413
- */
414
- transfer(to: `0x${string}`, value: bigint, options?: {
415
- accessList?: import("viem").AccessList;
416
- authorizationList?: import("viem").AuthorizationList;
417
- chain?: import("viem").Chain | null;
418
- dataSuffix?: `0x${string}`;
419
- gas?: bigint;
420
- gasPrice?: bigint;
421
- maxFeePerGas?: bigint;
422
- maxPriorityFeePerGas?: bigint;
423
- nonce?: number;
424
- value?: bigint;
425
- }): Promise<boolean>;
426
- /**
427
- * Simulate transferFrom
428
- * Returns gas estimate and result without sending transaction
429
- * @param options Optional transaction parameters (value, gas, nonce, etc.)
430
- */
431
- transferFrom(from: `0x${string}`, to: `0x${string}`, value: bigint, options?: {
432
- accessList?: import("viem").AccessList;
433
- authorizationList?: import("viem").AuthorizationList;
434
- chain?: import("viem").Chain | null;
435
- dataSuffix?: `0x${string}`;
436
- gas?: bigint;
437
- gasPrice?: bigint;
438
- maxFeePerGas?: bigint;
439
- maxPriorityFeePerGas?: bigint;
440
- nonce?: number;
441
- value?: bigint;
442
- }): Promise<boolean>;
443
- };
444
- /**
445
- * Watch contract events
446
- *
447
- * @example
448
- * // Watch all Transfer events
449
- * const unwatch = contract.watch.Transfer((event) => {
450
- * console.log('Transfer:', event);
451
- * });
452
- *
453
- * // Stop watching
454
- * unwatch();
455
- */
456
- get watch(): {
457
- /**
458
- * Watch Approval events
459
- * @param callback Function to call when event is emitted
460
- * @param filter Optional filter for indexed parameters
461
- * @returns Unwatch function to stop listening
462
- */
463
- Approval: (callback: (event: {
464
- owner: `0x${string}`;
465
- spender: `0x${string}`;
466
- value: bigint;
467
- }) => void, filter?: {
468
- owner: `0x${string}`;
469
- spender: `0x${string}`;
470
- }) => () => void;
471
- /**
472
- * Watch Transfer events
473
- * @param callback Function to call when event is emitted
474
- * @param filter Optional filter for indexed parameters
475
- * @returns Unwatch function to stop listening
476
- */
477
- Transfer: (callback: (event: {
478
- from: `0x${string}`;
479
- to: `0x${string}`;
480
- value: bigint;
481
- }) => void, filter?: {
482
- from: `0x${string}`;
483
- to: `0x${string}`;
484
- }) => () => void;
485
- };
486
- }