@gitmyabi/basewallet 1.0.1 → 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,4 +1,2 @@
1
- export { Proxy_jsonAbi, Proxy_json } from './Proxy_json';
2
- export type { Proxy_jsonAbi as Proxy_jsonAbiType, Proxy_jsonContract } from './Proxy_json';
3
1
  export { BaseWallet_jsonAbi, BaseWallet_json } from './BaseWallet_json';
4
2
  export type { BaseWallet_jsonAbi as BaseWallet_jsonAbiType, BaseWallet_jsonContract } from './BaseWallet_json';
@@ -1,10 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.BaseWallet_json = exports.BaseWallet_jsonAbi = exports.Proxy_json = exports.Proxy_jsonAbi = void 0;
3
+ exports.BaseWallet_json = exports.BaseWallet_jsonAbi = void 0;
4
4
  // Auto-generated exports for all contracts
5
- var Proxy_json_1 = require("./Proxy_json");
6
- Object.defineProperty(exports, "Proxy_jsonAbi", { enumerable: true, get: function () { return Proxy_json_1.Proxy_jsonAbi; } });
7
- Object.defineProperty(exports, "Proxy_json", { enumerable: true, get: function () { return Proxy_json_1.Proxy_json; } });
8
5
  var BaseWallet_json_1 = require("./BaseWallet_json");
9
6
  Object.defineProperty(exports, "BaseWallet_jsonAbi", { enumerable: true, get: function () { return BaseWallet_json_1.BaseWallet_jsonAbi; } });
10
7
  Object.defineProperty(exports, "BaseWallet_json", { enumerable: true, get: function () { return BaseWallet_json_1.BaseWallet_json; } });
@@ -1,5 +1,3 @@
1
1
  // Auto-generated exports for all contracts
2
- export { Proxy_jsonAbi, Proxy_json } from './Proxy_json';
3
- export type { Proxy_jsonAbi as Proxy_jsonAbiType, Proxy_jsonContract } from './Proxy_json';
4
2
  export { BaseWallet_jsonAbi, BaseWallet_json } from './BaseWallet_json';
5
3
  export type { BaseWallet_jsonAbi as BaseWallet_jsonAbiType, BaseWallet_jsonContract } from './BaseWallet_json';
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@gitmyabi/basewallet",
3
- "version": "1.0.1",
4
- "description": "Auto-generated TypeScript type bindings for BaseWallet (build etherscan-basewallet-e24f1567-1789344724375, commit 5ae3011, branch etherscan)",
3
+ "version": "1.0.3",
4
+ "description": "Auto-generated TypeScript type bindings for BaseWallet (build etherscan-basewallet-b6d64221-1790544139002, commit b3f2bbc, 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/basewallet"
40
40
  },
41
41
  "branch": "etherscan",
42
- "shortHash": "5ae3011"
42
+ "shortHash": "b3f2bbc"
43
43
  }
@@ -1,132 +0,0 @@
1
- import type { Address, PublicClient, WalletClient } from 'viem';
2
- /**
3
- * Proxy_json ABI
4
- *
5
- * This ABI is typed using viem's type system for full type safety.
6
- */
7
- export declare const Proxy_jsonAbi: readonly [{
8
- readonly inputs: readonly [{
9
- readonly internalType: "address";
10
- readonly name: "_implementation";
11
- readonly type: "address";
12
- }];
13
- readonly stateMutability: "nonpayable";
14
- readonly type: "constructor";
15
- }, {
16
- readonly anonymous: false;
17
- readonly inputs: readonly [{
18
- readonly indexed: true;
19
- readonly internalType: "uint256";
20
- readonly name: "value";
21
- readonly type: "uint256";
22
- }, {
23
- readonly indexed: true;
24
- readonly internalType: "address";
25
- readonly name: "sender";
26
- readonly type: "address";
27
- }, {
28
- readonly indexed: false;
29
- readonly internalType: "bytes";
30
- readonly name: "data";
31
- readonly type: "bytes";
32
- }];
33
- readonly name: "Received";
34
- readonly type: "event";
35
- }, {
36
- readonly stateMutability: "payable";
37
- readonly type: "fallback";
38
- }, {
39
- readonly stateMutability: "payable";
40
- readonly type: "receive";
41
- }];
42
- /**
43
- * Type-safe ABI for Proxy_json
44
- */
45
- export type Proxy_jsonAbi = typeof Proxy_jsonAbi;
46
- /**
47
- * Contract instance type for Proxy_json
48
- */
49
- export type Proxy_jsonContract = any;
50
- /**
51
- * Proxy_json Contract Class
52
- *
53
- * Provides a class-based API similar to TypeChain for interacting with the contract.
54
- *
55
- * @example
56
- * ```typescript
57
- * import { createPublicClient, createWalletClient, http } from 'viem';
58
- * import { mainnet } from 'viem/chains';
59
- * import { Proxy_json } from 'Proxy_json';
60
- *
61
- * const publicClient = createPublicClient({ chain: mainnet, transport: http() });
62
- * const walletClient = createWalletClient({ chain: mainnet, transport: http() });
63
- *
64
- * const contract = new Proxy_json('0x...', { publicClient, walletClient });
65
- *
66
- * // Read functions
67
- * const result = await contract.balanceOf('0x...');
68
- *
69
- * // Write functions
70
- * const hash = await contract.transfer('0x...', 1000n);
71
- *
72
- * // Simulate transactions (dry-run)
73
- * const simulation = await contract.simulate.transfer('0x...', 1000n);
74
- * console.log('Gas estimate:', simulation.request.gas);
75
- *
76
- * // Watch events
77
- * const unwatch = contract.watch.Transfer((event) => {
78
- * console.log('Transfer event:', event);
79
- * });
80
- * ```
81
- */
82
- export declare class Proxy_json {
83
- private contract;
84
- private contractAddress;
85
- private publicClient;
86
- constructor(address: Address, clients: {
87
- publicClient: PublicClient;
88
- walletClient?: WalletClient;
89
- });
90
- /**
91
- * Get the contract address
92
- */
93
- get address(): Address;
94
- /**
95
- * Get the underlying viem contract instance
96
- */
97
- getContract(): Proxy_jsonContract;
98
- /**
99
- * Simulate contract write operations (dry-run without sending transaction)
100
- *
101
- * Note: This contract has no write functions, so simulate returns an empty object.
102
- */
103
- get simulate(): {};
104
- /**
105
- * Watch contract events
106
- *
107
- * @example
108
- * // Watch all Transfer events
109
- * const unwatch = contract.watch.Transfer((event) => {
110
- * console.log('Transfer:', event);
111
- * });
112
- *
113
- * // Stop watching
114
- * unwatch();
115
- */
116
- get watch(): {
117
- /**
118
- * Watch Received events
119
- * @param callback Function to call when event is emitted
120
- * @param filter Optional filter for indexed parameters
121
- * @returns Unwatch function to stop listening
122
- */
123
- Received: (callback: (event: {
124
- value: bigint;
125
- sender: `0x${string}`;
126
- data: `0x${string}`;
127
- }) => void, filter?: {
128
- value: bigint;
129
- sender: `0x${string}`;
130
- }) => () => void;
131
- };
132
- }
@@ -1,159 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Proxy_json = exports.Proxy_jsonAbi = void 0;
4
- const viem_1 = require("viem");
5
- /**
6
- * Proxy_json ABI
7
- *
8
- * This ABI is typed using viem's type system for full type safety.
9
- */
10
- exports.Proxy_jsonAbi = [
11
- {
12
- "inputs": [
13
- {
14
- "internalType": "address",
15
- "name": "_implementation",
16
- "type": "address"
17
- }
18
- ],
19
- "stateMutability": "nonpayable",
20
- "type": "constructor"
21
- },
22
- {
23
- "anonymous": false,
24
- "inputs": [
25
- {
26
- "indexed": true,
27
- "internalType": "uint256",
28
- "name": "value",
29
- "type": "uint256"
30
- },
31
- {
32
- "indexed": true,
33
- "internalType": "address",
34
- "name": "sender",
35
- "type": "address"
36
- },
37
- {
38
- "indexed": false,
39
- "internalType": "bytes",
40
- "name": "data",
41
- "type": "bytes"
42
- }
43
- ],
44
- "name": "Received",
45
- "type": "event"
46
- },
47
- {
48
- "stateMutability": "payable",
49
- "type": "fallback"
50
- },
51
- {
52
- "stateMutability": "payable",
53
- "type": "receive"
54
- }
55
- ];
56
- /**
57
- * Proxy_json Contract Class
58
- *
59
- * Provides a class-based API similar to TypeChain for interacting with the contract.
60
- *
61
- * @example
62
- * ```typescript
63
- * import { createPublicClient, createWalletClient, http } from 'viem';
64
- * import { mainnet } from 'viem/chains';
65
- * import { Proxy_json } from 'Proxy_json';
66
- *
67
- * const publicClient = createPublicClient({ chain: mainnet, transport: http() });
68
- * const walletClient = createWalletClient({ chain: mainnet, transport: http() });
69
- *
70
- * const contract = new Proxy_json('0x...', { publicClient, walletClient });
71
- *
72
- * // Read functions
73
- * const result = await contract.balanceOf('0x...');
74
- *
75
- * // Write functions
76
- * const hash = await contract.transfer('0x...', 1000n);
77
- *
78
- * // Simulate transactions (dry-run)
79
- * const simulation = await contract.simulate.transfer('0x...', 1000n);
80
- * console.log('Gas estimate:', simulation.request.gas);
81
- *
82
- * // Watch events
83
- * const unwatch = contract.watch.Transfer((event) => {
84
- * console.log('Transfer event:', event);
85
- * });
86
- * ```
87
- */
88
- class Proxy_json {
89
- constructor(address, clients) {
90
- this.contractAddress = address;
91
- this.publicClient = clients.publicClient;
92
- this.contract = (0, viem_1.getContract)({
93
- address,
94
- abi: exports.Proxy_jsonAbi,
95
- client: {
96
- public: clients.publicClient,
97
- wallet: clients.walletClient,
98
- },
99
- });
100
- }
101
- /**
102
- * Get the contract address
103
- */
104
- get address() {
105
- return this.contractAddress;
106
- }
107
- /**
108
- * Get the underlying viem contract instance
109
- */
110
- getContract() {
111
- return this.contract;
112
- }
113
- // No read functions
114
- // No write functions
115
- /**
116
- * Simulate contract write operations (dry-run without sending transaction)
117
- *
118
- * Note: This contract has no write functions, so simulate returns an empty object.
119
- */
120
- get simulate() {
121
- return {};
122
- }
123
- /**
124
- * Watch contract events
125
- *
126
- * @example
127
- * // Watch all Transfer events
128
- * const unwatch = contract.watch.Transfer((event) => {
129
- * console.log('Transfer:', event);
130
- * });
131
- *
132
- * // Stop watching
133
- * unwatch();
134
- */
135
- get watch() {
136
- return {
137
- /**
138
- * Watch Received events
139
- * @param callback Function to call when event is emitted
140
- * @param filter Optional filter for indexed parameters
141
- * @returns Unwatch function to stop listening
142
- */
143
- Received: (callback, filter) => {
144
- return this.publicClient.watchContractEvent({
145
- address: this.contractAddress,
146
- abi: exports.Proxy_jsonAbi,
147
- eventName: 'Received',
148
- args: filter,
149
- onLogs: (logs) => {
150
- logs.forEach((log) => {
151
- callback(log.args);
152
- });
153
- },
154
- });
155
- }
156
- };
157
- }
158
- }
159
- exports.Proxy_json = Proxy_json;
@@ -1,188 +0,0 @@
1
- import type { Abi, Address, PublicClient, WalletClient, GetContractReturnType } from 'viem';
2
- import { getContract } from 'viem';
3
-
4
- /**
5
- * Proxy_json ABI
6
- *
7
- * This ABI is typed using viem's type system for full type safety.
8
- */
9
- export const Proxy_jsonAbi = [
10
- {
11
- "inputs": [
12
- {
13
- "internalType": "address",
14
- "name": "_implementation",
15
- "type": "address"
16
- }
17
- ],
18
- "stateMutability": "nonpayable",
19
- "type": "constructor"
20
- },
21
- {
22
- "anonymous": false,
23
- "inputs": [
24
- {
25
- "indexed": true,
26
- "internalType": "uint256",
27
- "name": "value",
28
- "type": "uint256"
29
- },
30
- {
31
- "indexed": true,
32
- "internalType": "address",
33
- "name": "sender",
34
- "type": "address"
35
- },
36
- {
37
- "indexed": false,
38
- "internalType": "bytes",
39
- "name": "data",
40
- "type": "bytes"
41
- }
42
- ],
43
- "name": "Received",
44
- "type": "event"
45
- },
46
- {
47
- "stateMutability": "payable",
48
- "type": "fallback"
49
- },
50
- {
51
- "stateMutability": "payable",
52
- "type": "receive"
53
- }
54
- ] as const satisfies Abi;
55
-
56
- /**
57
- * Type-safe ABI for Proxy_json
58
- */
59
- export type Proxy_jsonAbi = typeof Proxy_jsonAbi;
60
-
61
- /**
62
- * Contract instance type for Proxy_json
63
- */
64
- // Use any for contract type to avoid complex viem type issues
65
- // The runtime behavior is type-safe through viem's ABI typing
66
- export type Proxy_jsonContract = any;
67
-
68
- /**
69
- * Proxy_json Contract Class
70
- *
71
- * Provides a class-based API similar to TypeChain for interacting with the contract.
72
- *
73
- * @example
74
- * ```typescript
75
- * import { createPublicClient, createWalletClient, http } from 'viem';
76
- * import { mainnet } from 'viem/chains';
77
- * import { Proxy_json } from 'Proxy_json';
78
- *
79
- * const publicClient = createPublicClient({ chain: mainnet, transport: http() });
80
- * const walletClient = createWalletClient({ chain: mainnet, transport: http() });
81
- *
82
- * const contract = new Proxy_json('0x...', { publicClient, walletClient });
83
- *
84
- * // Read functions
85
- * const result = await contract.balanceOf('0x...');
86
- *
87
- * // Write functions
88
- * const hash = await contract.transfer('0x...', 1000n);
89
- *
90
- * // Simulate transactions (dry-run)
91
- * const simulation = await contract.simulate.transfer('0x...', 1000n);
92
- * console.log('Gas estimate:', simulation.request.gas);
93
- *
94
- * // Watch events
95
- * const unwatch = contract.watch.Transfer((event) => {
96
- * console.log('Transfer event:', event);
97
- * });
98
- * ```
99
- */
100
- export class Proxy_json {
101
- private contract: Proxy_jsonContract;
102
- private contractAddress: Address;
103
- private publicClient: PublicClient;
104
-
105
- constructor(
106
- address: Address,
107
- clients: {
108
- publicClient: PublicClient;
109
- walletClient?: WalletClient;
110
- }
111
- ) {
112
- this.contractAddress = address;
113
- this.publicClient = clients.publicClient;
114
- this.contract = getContract({
115
- address,
116
- abi: Proxy_jsonAbi,
117
- client: {
118
- public: clients.publicClient,
119
- wallet: clients.walletClient,
120
- },
121
- });
122
- }
123
-
124
- /**
125
- * Get the contract address
126
- */
127
- get address(): Address {
128
- return this.contractAddress;
129
- }
130
-
131
- /**
132
- * Get the underlying viem contract instance
133
- */
134
- getContract(): Proxy_jsonContract {
135
- return this.contract;
136
- }
137
-
138
- // No read functions
139
-
140
- // No write functions
141
-
142
-
143
-
144
- /**
145
- * Simulate contract write operations (dry-run without sending transaction)
146
- *
147
- * Note: This contract has no write functions, so simulate returns an empty object.
148
- */
149
- get simulate() {
150
- return {};
151
- }
152
-
153
- /**
154
- * Watch contract events
155
- *
156
- * @example
157
- * // Watch all Transfer events
158
- * const unwatch = contract.watch.Transfer((event) => {
159
- * console.log('Transfer:', event);
160
- * });
161
- *
162
- * // Stop watching
163
- * unwatch();
164
- */
165
- get watch() {
166
- return {
167
- /**
168
- * Watch Received events
169
- * @param callback Function to call when event is emitted
170
- * @param filter Optional filter for indexed parameters
171
- * @returns Unwatch function to stop listening
172
- */
173
- Received: (callback: (event: { value: bigint; sender: `0x${string}`; data: `0x${string}` }) => void, filter?: { value: bigint; sender: `0x${string}` }) => {
174
- return this.publicClient.watchContractEvent({
175
- address: this.contractAddress,
176
- abi: Proxy_jsonAbi,
177
- eventName: 'Received',
178
- args: filter,
179
- onLogs: (logs: any[]) => {
180
- logs.forEach((log: any) => {
181
- callback(log.args as any);
182
- });
183
- },
184
- }) as () => void;
185
- }
186
- };
187
- }
188
- }