viem 0.2.0-canary.20230316T042447 → 0.2.0-jxom-async-verify-message.20230321T000803

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 (57) hide show
  1. package/dist/abi.d.ts +3 -3
  2. package/dist/abi.js +2 -2
  3. package/dist/abi.mjs +1 -1
  4. package/dist/account-07d04222.d.ts +74 -0
  5. package/dist/{chain-1b53ef88.d.ts → chain-b2e88e30.d.ts} +113 -108
  6. package/dist/{chain-ec8c485d.d.ts → chain-c4f924cf.d.ts} +1 -1
  7. package/dist/chains.d.ts +3 -3
  8. package/dist/chains.js +63 -63
  9. package/dist/chains.mjs +1 -1
  10. package/dist/{chunk-A5BRAPQQ.js → chunk-22BDIC7J.js} +404 -106
  11. package/dist/chunk-22BDIC7J.js.map +1 -0
  12. package/dist/{chunk-GZ67J32T.js → chunk-2NJCP2DN.js} +19 -19
  13. package/dist/{chunk-GZ67J32T.js.map → chunk-2NJCP2DN.js.map} +1 -1
  14. package/dist/{chunk-ISLCPEI2.mjs → chunk-FEPL5HFW.mjs} +334 -36
  15. package/dist/chunk-FEPL5HFW.mjs.map +1 -0
  16. package/dist/{chunk-PLALZ2GD.mjs → chunk-OZCG5IO7.mjs} +2 -2
  17. package/dist/chunk-OZCG5IO7.mjs.map +1 -0
  18. package/dist/contract.d.ts +8 -7
  19. package/dist/contract.js +2 -2
  20. package/dist/contract.mjs +1 -1
  21. package/dist/{createClient-a28317a9.d.ts → createClient-d4f1dea1.d.ts} +6 -6
  22. package/dist/{createPublicClient-75540130.d.ts → createPublicClient-3a714a8d.d.ts} +154 -207
  23. package/dist/{eip1193-4f4e240c.d.ts → eip1193-cd3e872a.d.ts} +1 -1
  24. package/dist/{encodeFunctionResult-1f324375.d.ts → encodeFunctionResult-750c9055.d.ts} +1 -1
  25. package/dist/{encodePacked-d5d5264a.d.ts → encodePacked-de74201f.d.ts} +1 -1
  26. package/dist/ens.d.ts +5 -4
  27. package/dist/ens.js +3 -3
  28. package/dist/ens.mjs +2 -2
  29. package/dist/ethers.d.ts +3 -5
  30. package/dist/ethers.js +3 -3
  31. package/dist/ethers.mjs +1 -1
  32. package/dist/{formatAbiItem-15e8817d.d.ts → formatAbiItem-fdbdda39.d.ts} +1 -1
  33. package/dist/{getAbiItem-3e809ff9.d.ts → getAbiItem-9d709e3b.d.ts} +1 -1
  34. package/dist/index.d.ts +14 -13
  35. package/dist/index.js +99 -91
  36. package/dist/index.js.map +1 -1
  37. package/dist/index.mjs +11 -3
  38. package/dist/index.mjs.map +1 -1
  39. package/dist/{parseGwei-6fff7cbe.d.ts → parseGwei-b138c041.d.ts} +49 -12
  40. package/dist/public.d.ts +5 -4
  41. package/dist/public.js +2 -2
  42. package/dist/public.mjs +1 -1
  43. package/dist/{test-2bd23d7e.d.ts → test-c70126a6.d.ts} +33 -32
  44. package/dist/test.d.ts +10 -10
  45. package/dist/test.js +2 -2
  46. package/dist/test.mjs +1 -1
  47. package/dist/utils/index.d.ts +28 -18
  48. package/dist/utils/index.js +10 -2
  49. package/dist/utils/index.mjs +11 -3
  50. package/dist/wallet.d.ts +5 -4
  51. package/dist/wallet.js +2 -2
  52. package/dist/wallet.mjs +1 -1
  53. package/dist/window.d.ts +2 -2
  54. package/package.json +1 -1
  55. package/dist/chunk-A5BRAPQQ.js.map +0 -1
  56. package/dist/chunk-ISLCPEI2.mjs.map +0 -1
  57. package/dist/chunk-PLALZ2GD.mjs.map +0 -1
@@ -1,27 +1,10 @@
1
- import { W as WalletPermission, a as WatchAssetParams, P as PublicRequests } from './eip1193-4f4e240c.js';
2
- import { a as Transport, b as ClientConfig, C as Client } from './createClient-a28317a9.js';
3
- import { Abi, Narrow, Address, AbiEvent, ExtractAbiEvent, TypedData, TypedDataDomain, TypedDataToPrimitiveTypes } from 'abitype';
4
- import { C as Chain, H as Hex, h as ExtractConstructorArgsFromAbi, W as ExtractFormatter, a1 as Formatters, a2 as Formatter, X as Formatted, c as Block, R as RpcBlock, O as Transaction, T as TransactionReceipt, z as RpcTransactionReceipt, a3 as TransactionType, D as RpcTransactionRequest, I as TransactionRequest, f as BlockTag, a4 as MergeIntersectionProperties, g as ContractConfig, a5 as GetValue, p as ExtractResultFromAbi, a6 as MaybeAbiEventName, a7 as MaybeExtractEventArgsFromAbi, e as BlockNumber, m as ExtractEventNameFromAbi, a as Hash, F as FeeHistory, L as Log, Y as FormattedTransaction, Z as TransactionFormatter, k as ExtractEventArgsFromAbi, a8 as Prettify } from './chain-1b53ef88.js';
1
+ import { W as WalletPermission, a as WatchAssetParams, P as PublicRequests } from './eip1193-cd3e872a.js';
2
+ import { a as Transport, b as ClientConfig, C as Client } from './createClient-d4f1dea1.js';
3
+ import { Address, Abi, Narrow, TypedData, AbiEvent, ExtractAbiEvent } from 'abitype';
4
+ import { A as Account, G as GetAccountParameter, T as TypedDataDefinition, P as ParseAccount } from './account-07d04222.js';
5
+ import { C as Chain, W as ExtractFormatter, a1 as Formatters, a2 as Formatter, X as Formatted, c as Block, R as RpcBlock, O as Transaction, T as TransactionReceipt, z as RpcTransactionReceipt, a3 as TransactionType, D as RpcTransactionRequest, I as TransactionRequest, f as BlockTag, H as Hex, a4 as MergeIntersectionProperties, a5 as GetChain, h as ExtractConstructorArgsFromAbi, a as Hash, a6 as GetValue, g as ContractConfig, p as ExtractResultFromAbi, a7 as MaybeAbiEventName, a8 as MaybeExtractEventArgsFromAbi, e as BlockNumber, m as ExtractEventNameFromAbi, F as FeeHistory, L as Log, Y as FormattedTransaction, Z as TransactionFormatter, k as ExtractEventArgsFromAbi, a9 as Prettify } from './chain-b2e88e30.js';
5
6
 
6
- type AddChainParameters = {
7
- chain: Chain;
8
- };
9
- declare function addChain(client: WalletClient, { chain }: AddChainParameters): Promise<void>;
10
-
11
- type DeployContractParameters<TChain extends Chain = Chain, TAbi extends Abi | readonly unknown[] = Abi> = Omit<SendTransactionParameters<TChain>, 'accessList' | 'to' | 'data' | 'value'> & {
12
- abi: Narrow<TAbi>;
13
- bytecode: Hex;
14
- } & ExtractConstructorArgsFromAbi<TAbi>;
15
- type DeployContractReturnType = SendTransactionReturnType;
16
- declare function deployContract<TChain extends Chain, TAbi extends Abi | readonly unknown[]>(walletClient: WalletClient, { abi, args, bytecode, ...request }: DeployContractParameters<TChain, TAbi>): Promise<DeployContractReturnType>;
17
-
18
- type GetAddressesReturnType = Address[];
19
- declare function getAddresses(client: WalletClient): Promise<GetAddressesReturnType>;
20
-
21
- type GetChainIdReturnType = number;
22
- declare function getChainId(client: PublicClient | WalletClient): Promise<GetChainIdReturnType>;
23
-
24
- type BlockFormatter<TChain extends Chain = Chain> = ExtractFormatter<TChain, 'block', NonNullable<Formatters['block']>>;
7
+ type BlockFormatter<TChain extends Chain | undefined = Chain> = TChain extends Chain ? ExtractFormatter<TChain, 'block', NonNullable<Formatters['block']>> : Formatters['block'];
25
8
  type FormattedBlock<TFormatter extends Formatter | undefined = Formatter> = Formatted<TFormatter, Block>;
26
9
  declare function formatBlock(block: Partial<RpcBlock>): Block<bigint, Transaction<bigint, number>>;
27
10
  declare const defineBlock: <TFormat extends Formatter<Partial<RpcBlock>, Partial<Block<bigint, Transaction<bigint, number>>> & {
@@ -33,7 +16,7 @@ declare const defineBlock: <TFormat extends Formatter<Partial<RpcBlock>, Partial
33
16
  [key: string]: unknown;
34
17
  }) => Block<bigint, Transaction<bigint, number>> & ReturnType<TFormat> & { [K in TExclude[number]]: never; };
35
18
 
36
- type TransactionReceiptFormatter<TChain extends Chain = Chain> = ExtractFormatter<TChain, 'transactionReceipt', NonNullable<Formatters['transactionReceipt']>>;
19
+ type TransactionReceiptFormatter<TChain extends Chain | undefined = Chain> = TChain extends Chain ? ExtractFormatter<TChain, 'transactionReceipt', NonNullable<Formatters['transactionReceipt']>> : Formatters['transactionReceipt'];
37
20
  type FormattedTransactionReceipt<TFormatter extends Formatter | undefined = Formatter> = Formatted<TFormatter, TransactionReceipt>;
38
21
  declare const defineTransactionReceipt: <TFormat extends Formatter<Partial<RpcTransactionReceipt>, Partial<TransactionReceipt<bigint, number, "success" | "reverted", TransactionType>> & {
39
22
  [key: string]: unknown;
@@ -44,7 +27,7 @@ declare const defineTransactionReceipt: <TFormat extends Formatter<Partial<RpcTr
44
27
  [key: string]: unknown;
45
28
  }) => TransactionReceipt<bigint, number, "success" | "reverted", TransactionType> & ReturnType<TFormat> & { [K in TExclude[number]]: never; };
46
29
 
47
- type TransactionRequestFormatter<TChain extends Chain = Chain> = ExtractFormatter<TChain, 'transactionRequest', NonNullable<Formatters['transactionRequest']>>;
30
+ type TransactionRequestFormatter<TChain extends Chain | undefined = Chain> = TChain extends Chain ? ExtractFormatter<TChain, 'transactionRequest', NonNullable<Formatters['transactionRequest']>> : Formatters['transactionRequest'];
48
31
  type FormattedTransactionRequest$1<TFormatter extends Formatter | undefined = Formatter> = Formatted<TFormatter, RpcTransactionRequest>;
49
32
  declare function formatTransactionRequest(transactionRequest: Partial<TransactionRequest>): RpcTransactionRequest;
50
33
  declare const defineTransactionRequest: <TFormat extends Formatter<Partial<TransactionRequest<bigint, number>>, Partial<RpcTransactionRequest> & {
@@ -57,8 +40,8 @@ declare const defineTransactionRequest: <TFormat extends Formatter<Partial<Trans
57
40
  }) => RpcTransactionRequest & ReturnType<TFormat> & { [K in TExclude[number]]: never; };
58
41
 
59
42
  type FormattedCall<TFormatter extends Formatter | undefined = Formatter> = MergeIntersectionProperties<Omit<Formatted<TFormatter, TransactionRequest, true>, 'from'>, TransactionRequest>;
60
- type CallParameters<TChain extends Chain = Chain> = FormattedCall<TransactionRequestFormatter<TChain>> & {
61
- account?: Account;
43
+ type CallParameters<TChain extends Chain | undefined = Chain> = FormattedCall<TransactionRequestFormatter<TChain>> & {
44
+ account?: Account | Address;
62
45
  } & ({
63
46
  /** The balance of the account at a block number. */
64
47
  blockNumber?: bigint;
@@ -71,24 +54,97 @@ type CallParameters<TChain extends Chain = Chain> = FormattedCall<TransactionReq
71
54
  type CallReturnType = {
72
55
  data: Hex | undefined;
73
56
  };
74
- declare function call<TChain extends Chain>(client: PublicClient<any, TChain>, args: CallParameters<TChain>): Promise<CallReturnType>;
57
+ declare function call<TChain extends Chain | undefined>(client: PublicClientArg<Transport, TChain>, args: CallParameters<TChain>): Promise<CallReturnType>;
58
+
59
+ type AddChainParameters = {
60
+ chain: Chain;
61
+ };
62
+ declare function addChain(client: WalletClientArg, { chain }: AddChainParameters): Promise<void>;
63
+
64
+ type DeployContractParameters<TChain extends Chain | undefined = Chain | undefined, TAbi extends Abi | readonly unknown[] = Abi, TAccount extends Account | undefined = undefined, TChainOverride extends Chain | undefined = TChain> = Omit<SendTransactionParameters<TChain, TAccount, TChainOverride>, 'accessList' | 'chain' | 'to' | 'data' | 'value'> & {
65
+ abi: Narrow<TAbi>;
66
+ bytecode: Hex;
67
+ } & GetChain<TChain, TChainOverride> & ExtractConstructorArgsFromAbi<TAbi>;
68
+ type DeployContractReturnType = SendTransactionReturnType;
69
+ declare function deployContract<TChain extends Chain | undefined, TAbi extends Abi | readonly unknown[], TAccount extends Account | undefined, TChainOverride extends Chain | undefined = TChain>(walletClient: WalletClientArg<Transport, TChain, TAccount>, { abi, args, bytecode, ...request }: DeployContractParameters<TChain, TAbi, TAccount, TChainOverride>): Promise<DeployContractReturnType>;
70
+
71
+ type GetAddressesReturnType = Address[];
72
+ declare function getAddresses(client: WalletClientArg): Promise<GetAddressesReturnType>;
73
+
74
+ type GetChainIdReturnType = number;
75
+ declare function getChainId(client: PublicClientArg | WalletClientArg): Promise<GetChainIdReturnType>;
76
+
77
+ type GetPermissionsReturnType = WalletPermission[];
78
+ declare function getPermissions(client: WalletClientArg): Promise<WalletPermission[]>;
79
+
80
+ type RequestAddressesReturnType = Address[];
81
+ declare function requestAddresses(client: WalletClientArg): Promise<RequestAddressesReturnType>;
82
+
83
+ type RequestPermissionsParameters = {
84
+ eth_accounts: Record<string, any>;
85
+ } & {
86
+ [key: string]: Record<string, any>;
87
+ };
88
+ type RequestPermissionsReturnType = WalletPermission[];
89
+ declare function requestPermissions(client: WalletClientArg, permissions: RequestPermissionsParameters): Promise<WalletPermission[]>;
90
+
91
+ type FormattedTransactionRequest<TFormatter extends Formatter | undefined = Formatter> = MergeIntersectionProperties<Omit<Formatted<TFormatter, TransactionRequest, true>, 'from'>, TransactionRequest>;
92
+ type SendTransactionParameters<TChain extends Chain | undefined = Chain, TAccount extends Account | undefined = undefined, TChainOverride extends Chain | undefined = TChain> = FormattedTransactionRequest<TransactionRequestFormatter<TChainOverride>> & GetAccountParameter<TAccount> & GetChain<TChain, TChainOverride>;
93
+ type SendTransactionReturnType = Hash;
94
+ declare function sendTransaction<TChain extends Chain | undefined, TAccount extends Account | undefined, TChainOverride extends Chain | undefined = TChain>(client: WalletClientArg<Transport, TChain, TAccount>, args: SendTransactionParameters<TChain, TAccount, TChainOverride>): Promise<SendTransactionReturnType>;
95
+
96
+ type SignMessageParameters<TAccount extends Account | undefined = undefined> = GetAccountParameter<TAccount> & ({
97
+ /** @deprecated – `data` will be removed in 0.2.0; use `message` instead. */
98
+ data: string;
99
+ message?: never;
100
+ } | {
101
+ data?: never;
102
+ message: string;
103
+ });
104
+ type SignMessageReturnType = Hex;
105
+ declare function signMessage<TAccount extends Account | undefined>(client: WalletClientArg<Transport, Chain | undefined, TAccount>, { account: account_, data, message, }: SignMessageParameters<TAccount>): Promise<SignMessageReturnType>;
75
106
 
76
- type SimulateContractParameters<TChain extends Chain = Chain, TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = any, TChainOverride extends Chain | undefined = undefined> = Omit<CallParameters<TChainOverride extends Chain ? TChainOverride : TChain>, 'to' | 'data' | 'value'> & {
107
+ type SignTypedDataParameters<TTypedData extends TypedData | {
108
+ [key: string]: unknown;
109
+ } = TypedData, TPrimaryType extends string = string, TAccount extends Account | undefined = undefined> = GetAccountParameter<TAccount> & TypedDataDefinition<TTypedData, TPrimaryType>;
110
+ type SignTypedDataReturnType = Hex;
111
+ declare function signTypedData<TTypedData extends TypedData | {
112
+ [key: string]: unknown;
113
+ }, TPrimaryType extends string = string, TAccount extends Account | undefined = undefined>(client: WalletClientArg<Transport, Chain | undefined, TAccount>, { account: account_, domain, message, primaryType, types: types_, }: SignTypedDataParameters<TTypedData, TPrimaryType, TAccount>): Promise<SignTypedDataReturnType>;
114
+
115
+ type SwitchChainParameters = {
116
+ id: Chain['id'];
117
+ };
118
+ declare function switchChain(client: WalletClientArg, { id }: SwitchChainParameters): Promise<void>;
119
+
120
+ type WatchAssetParameters = WatchAssetParams;
121
+ type WatchAssetReturnType = boolean;
122
+ declare function watchAsset(client: WalletClientArg, params: WatchAssetParameters): Promise<WatchAssetReturnType>;
123
+
124
+ type WriteContractParameters<TChain extends Chain | undefined = Chain, TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = string, TAccount extends Account | undefined = undefined, TChainOverride extends Chain | undefined = TChain> = Omit<SendTransactionParameters<TChain, TAccount, TChainOverride>, 'chain' | 'to' | 'data' | 'value'> & {
125
+ value?: GetValue<TAbi, TFunctionName, SendTransactionParameters<TChain>['value']>;
126
+ } & GetChain<TChain, TChainOverride> & ContractConfig<TAbi, TFunctionName, 'payable' | 'nonpayable'>;
127
+ type WriteContractReturnType = SendTransactionReturnType;
128
+ declare function writeContract<TChain extends Chain | undefined, TAbi extends Abi | readonly unknown[], TFunctionName extends string, TAccount extends Account | undefined, TChainOverride extends Chain | undefined = TChain>(client: WalletClientArg<Transport, TChain, TAccount>, { abi, address, args, functionName, ...request }: WriteContractParameters<TChain, TAbi, TFunctionName, TAccount, TChainOverride>): Promise<WriteContractReturnType>;
129
+
130
+ type SimulateContractParameters<TChain extends Chain | undefined = Chain, TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = any, TChainOverride extends Chain | undefined = undefined> = Omit<CallParameters<TChainOverride extends Chain ? TChainOverride : TChain>, 'to' | 'data' | 'value'> & {
77
131
  chain?: TChainOverride;
78
132
  } & ContractConfig<TAbi, TFunctionName, 'payable' | 'nonpayable'> & {
79
133
  value?: GetValue<TAbi, TFunctionName, CallParameters<TChain>['value']>;
80
134
  };
81
- type SimulateContractReturnType<TChain extends Chain = Chain, TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = string> = {
135
+ type SimulateContractReturnType<TChain extends Chain | undefined = Chain, TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = string, TChainOverride extends Chain | undefined = TChain> = {
82
136
  result: ExtractResultFromAbi<TAbi, TFunctionName>;
83
- request: WriteContractParameters<TChain, TAbi, TFunctionName> & ContractConfig<TAbi, TFunctionName, 'payable' | 'nonpayable'>;
137
+ request: Omit<WriteContractParameters<TChain, TAbi, TFunctionName, undefined, TChainOverride>, 'chain'> & {
138
+ chain: TChainOverride;
139
+ } & ContractConfig<TAbi, TFunctionName, 'payable' | 'nonpayable'>;
84
140
  };
85
- declare function simulateContract<TChain extends Chain, TAbi extends Abi | readonly unknown[], TFunctionName extends string, TChainOverride extends Chain | undefined>(client: PublicClient<any, TChain>, { abi, address, args, functionName, ...callRequest }: SimulateContractParameters<TChain, TAbi, TFunctionName, TChainOverride>): Promise<SimulateContractReturnType<TChainOverride extends Chain ? TChainOverride : TChain, TAbi, TFunctionName>>;
141
+ declare function simulateContract<TChain extends Chain | undefined, TAbi extends Abi | readonly unknown[], TFunctionName extends string, TChainOverride extends Chain | undefined>(client: PublicClientArg<Transport, TChain>, { abi, address, args, functionName, ...callRequest }: SimulateContractParameters<TChain, TAbi, TFunctionName, TChainOverride>): Promise<SimulateContractReturnType<TChain, TAbi, TFunctionName, TChainOverride>>;
86
142
 
87
143
  type CreatePendingTransactionFilterReturnType = Filter<'transaction'>;
88
- declare function createPendingTransactionFilter(client: PublicClient): Promise<CreatePendingTransactionFilterReturnType>;
144
+ declare function createPendingTransactionFilter(client: PublicClientArg): Promise<CreatePendingTransactionFilterReturnType>;
89
145
 
90
146
  type CreateBlockFilterReturnType = Filter<'block'>;
91
- declare function createBlockFilter(client: PublicClient): Promise<CreateBlockFilterReturnType>;
147
+ declare function createBlockFilter(client: PublicClientArg): Promise<CreateBlockFilterReturnType>;
92
148
 
93
149
  type CreateEventFilterParameters<TAbiEvent extends AbiEvent | undefined = undefined, TAbi extends Abi | readonly unknown[] = [TAbiEvent], TEventName extends string | undefined = MaybeAbiEventName<TAbiEvent>, TArgs extends MaybeExtractEventArgsFromAbi<TAbi, TEventName> | undefined = undefined> = {
94
150
  address?: Address | Address[];
@@ -108,7 +164,7 @@ type CreateEventFilterParameters<TAbiEvent extends AbiEvent | undefined = undefi
108
164
  event?: never;
109
165
  });
110
166
  type CreateEventFilterReturnType<TAbiEvent extends AbiEvent | undefined = undefined, TAbi extends Abi | readonly unknown[] = [TAbiEvent], TEventName extends string | undefined = MaybeAbiEventName<TAbiEvent>, TArgs extends MaybeExtractEventArgsFromAbi<TAbi, TEventName> | undefined = undefined> = Filter<'event', TAbi, TEventName, TArgs>;
111
- declare function createEventFilter<TAbiEvent extends AbiEvent | undefined, TAbi extends Abi | readonly unknown[] = [TAbiEvent], TEventName extends string | undefined = MaybeAbiEventName<TAbiEvent>, TArgs extends MaybeExtractEventArgsFromAbi<TAbi, TEventName> | undefined = undefined>(client: PublicClient, { address, args, event, fromBlock, toBlock, }?: CreateEventFilterParameters<TAbiEvent, TAbi, TEventName, TArgs>): Promise<CreateEventFilterReturnType<TAbiEvent, TAbi, TEventName, TArgs>>;
167
+ declare function createEventFilter<TAbiEvent extends AbiEvent | undefined, TAbi extends Abi | readonly unknown[] = [TAbiEvent], TEventName extends string | undefined = MaybeAbiEventName<TAbiEvent>, TArgs extends MaybeExtractEventArgsFromAbi<TAbi, TEventName> | undefined = undefined>(client: PublicClientArg, { address, args, event, fromBlock, toBlock, }?: CreateEventFilterParameters<TAbiEvent, TAbi, TEventName, TArgs>): Promise<CreateEventFilterReturnType<TAbiEvent, TAbi, TEventName, TArgs>>;
112
168
 
113
169
  type CreateContractEventFilterParameters<TAbi extends Abi | readonly unknown[] = Abi, TEventName extends string | undefined = undefined, TArgs extends MaybeExtractEventArgsFromAbi<TAbi, TEventName> | undefined = undefined> = {
114
170
  address?: Address | Address[];
@@ -124,12 +180,10 @@ type CreateContractEventFilterParameters<TAbi extends Abi | readonly unknown[] =
124
180
  args?: never;
125
181
  });
126
182
  type CreateContractEventFilterReturnType<TAbi extends Abi | readonly unknown[] = Abi, TEventName extends string | undefined = undefined, TArgs extends MaybeExtractEventArgsFromAbi<TAbi, TEventName> | undefined = undefined> = Filter<'event', TAbi, TEventName, TArgs>;
127
- declare function createContractEventFilter<TAbi extends Abi | readonly unknown[], TEventName extends string | undefined, TArgs extends MaybeExtractEventArgsFromAbi<TAbi, TEventName> | undefined>(client: PublicClient, { address, abi, args, eventName, fromBlock, toBlock, }: CreateContractEventFilterParameters<TAbi, TEventName, TArgs>): Promise<CreateContractEventFilterReturnType<TAbi, TEventName, TArgs>>;
183
+ declare function createContractEventFilter<TAbi extends Abi | readonly unknown[], TEventName extends string | undefined, TArgs extends MaybeExtractEventArgsFromAbi<TAbi, TEventName> | undefined>(client: PublicClientArg, { address, abi, args, eventName, fromBlock, toBlock, }: CreateContractEventFilterParameters<TAbi, TEventName, TArgs>): Promise<CreateContractEventFilterReturnType<TAbi, TEventName, TArgs>>;
128
184
 
129
185
  type FormattedEstimateGas<TFormatter extends Formatter | undefined = Formatter> = MergeIntersectionProperties<Omit<Formatted<TFormatter, TransactionRequest, true>, 'from'>, TransactionRequest>;
130
- type EstimateGasParameters<TChain extends Chain = Chain> = FormattedEstimateGas<TransactionRequestFormatter<TChain>> & {
131
- account: Account;
132
- } & ({
186
+ type EstimateGasParameters<TChain extends Chain | undefined = Chain, TAccount extends Account | undefined = undefined> = FormattedEstimateGas<TransactionRequestFormatter<TChain>> & GetAccountParameter<TAccount> & ({
133
187
  /** The balance of the account at a block number. */
134
188
  blockNumber?: bigint;
135
189
  blockTag?: never;
@@ -142,13 +196,13 @@ type EstimateGasReturnType = bigint;
142
196
  /**
143
197
  * @description Estimates the gas necessary to complete a transaction without submitting it to the network.
144
198
  */
145
- declare function estimateGas<TChain extends Chain>(client: PublicClient<any, TChain> | WalletClient, args: EstimateGasParameters<TChain>): Promise<EstimateGasReturnType>;
199
+ declare function estimateGas<TChain extends Chain | undefined, TAccount extends Account | undefined = undefined>(client: PublicClientArg<Transport, TChain> | WalletClientArg<Transport, TChain, TAccount>, args: EstimateGasParameters<TChain, TAccount>): Promise<EstimateGasReturnType>;
146
200
 
147
- type EstimateContractGasParameters<TChain extends Chain = Chain, TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = any> = Omit<EstimateGasParameters<TChain>, 'data' | 'to' | 'value'> & ContractConfig<TAbi, TFunctionName, 'payable' | 'nonpayable'> & {
201
+ type EstimateContractGasParameters<TChain extends Chain | undefined = Chain, TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = any> = Omit<EstimateGasParameters<TChain>, 'data' | 'to' | 'value'> & ContractConfig<TAbi, TFunctionName, 'payable' | 'nonpayable'> & {
148
202
  value?: GetValue<TAbi, TFunctionName, EstimateGasParameters<TChain>['value']>;
149
203
  };
150
204
  type EstimateContractGasReturnType = bigint;
151
- declare function estimateContractGas<TChain extends Chain, TAbi extends Abi | readonly unknown[], TFunctionName extends string>(client: PublicClient<any, TChain>, { abi, address, args, functionName, ...request }: EstimateContractGasParameters<TChain, TAbi, TFunctionName>): Promise<EstimateContractGasReturnType>;
205
+ declare function estimateContractGas<TChain extends Chain | undefined, TAbi extends Abi | readonly unknown[], TFunctionName extends string>(client: PublicClientArg<Transport, TChain>, { abi, address, args, functionName, ...request }: EstimateContractGasParameters<TChain, TAbi, TFunctionName>): Promise<EstimateContractGasReturnType>;
152
206
 
153
207
  type GetBalanceParameters = {
154
208
  /** The address of the account. */
@@ -166,7 +220,7 @@ type GetBalanceReturnType = bigint;
166
220
  /**
167
221
  * @description Returns the balance of an address in wei.
168
222
  */
169
- declare function getBalance(client: PublicClient, { address, blockNumber, blockTag }: GetBalanceParameters): Promise<GetBalanceReturnType>;
223
+ declare function getBalance(client: PublicClientArg, { address, blockNumber, blockTag }: GetBalanceParameters): Promise<GetBalanceReturnType>;
170
224
 
171
225
  type GetBlockParameters = {
172
226
  /** Whether or not to include transaction data in the response. */
@@ -187,8 +241,8 @@ type GetBlockParameters = {
187
241
  /** The block tag. Defaults to 'latest'. */
188
242
  blockTag?: BlockTag;
189
243
  });
190
- type GetBlockReturnType<TChain extends Chain = Chain> = FormattedBlock<BlockFormatter<TChain>>;
191
- declare function getBlock<TChain extends Chain>(client: PublicClient<any, TChain> | WalletClient, { blockHash, blockNumber, blockTag, includeTransactions, }?: GetBlockParameters): Promise<GetBlockReturnType<TChain>>;
244
+ type GetBlockReturnType<TChain extends Chain | undefined = Chain> = FormattedBlock<BlockFormatter<TChain>>;
245
+ declare function getBlock<TChain extends Chain | undefined>(client: PublicClientArg<Transport, TChain> | WalletClientArg<Transport, TChain>, { blockHash, blockNumber, blockTag, includeTransactions, }?: GetBlockParameters): Promise<GetBlockReturnType<TChain>>;
192
246
 
193
247
  type GetBlockNumberParameters = {
194
248
  /** The maximum age (in ms) of the cached value. */
@@ -220,7 +274,7 @@ declare function getBlockNumberCache(id: string): {
220
274
  /**
221
275
  * @description Returns the number of the most recent block seen.
222
276
  */
223
- declare function getBlockNumber(client: PublicClient<any, any, any>, { maxAge }?: GetBlockNumberParameters): Promise<GetBlockNumberReturnType>;
277
+ declare function getBlockNumber(client: PublicClientArg, { maxAge }?: GetBlockNumberParameters): Promise<GetBlockNumberReturnType>;
224
278
 
225
279
  type GetBlockTransactionCountParameters = {
226
280
  /** Hash of the block. */
@@ -239,7 +293,7 @@ type GetBlockTransactionCountParameters = {
239
293
  blockTag?: BlockTag;
240
294
  };
241
295
  type GetBlockTransactionCountReturnType = number;
242
- declare function getBlockTransactionCount<TChain extends Chain>(client: PublicClient<any, TChain>, { blockHash, blockNumber, blockTag, }?: GetBlockTransactionCountParameters): Promise<GetBlockTransactionCountReturnType>;
296
+ declare function getBlockTransactionCount<TChain extends Chain | undefined>(client: PublicClientArg<Transport, TChain>, { blockHash, blockNumber, blockTag, }?: GetBlockTransactionCountParameters): Promise<GetBlockTransactionCountReturnType>;
243
297
 
244
298
  type GetBytecodeParameters = {
245
299
  address: Address;
@@ -251,7 +305,7 @@ type GetBytecodeParameters = {
251
305
  blockTag?: never;
252
306
  });
253
307
  type GetBytecodeReturnType = Hex | undefined;
254
- declare function getBytecode(client: PublicClient, { address, blockNumber, blockTag }: GetBytecodeParameters): Promise<GetBytecodeReturnType>;
308
+ declare function getBytecode(client: PublicClientArg, { address, blockNumber, blockTag }: GetBytecodeParameters): Promise<GetBytecodeReturnType>;
255
309
 
256
310
  type GetFeeHistoryParameters = {
257
311
  blockCount: number;
@@ -267,25 +321,25 @@ type GetFeeHistoryReturnType = FeeHistory;
267
321
  /**
268
322
  * @description Returns a collection of historical gas information.
269
323
  */
270
- declare function getFeeHistory(client: PublicClient, { blockCount, blockNumber, blockTag, rewardPercentiles, }: GetFeeHistoryParameters): Promise<GetFeeHistoryReturnType>;
324
+ declare function getFeeHistory(client: PublicClientArg, { blockCount, blockNumber, blockTag, rewardPercentiles, }: GetFeeHistoryParameters): Promise<GetFeeHistoryReturnType>;
271
325
 
272
326
  type GetFilterChangesParameters<TFilterType extends FilterType = FilterType, TAbiEvent extends AbiEvent | undefined = undefined, TAbi extends Abi | readonly unknown[] = [TAbiEvent], TEventName extends string | undefined = MaybeAbiEventName<TAbiEvent>> = {
273
327
  filter: Filter<TFilterType, TAbi, TEventName, any>;
274
328
  };
275
329
  type GetFilterChangesReturnType<TFilterType extends FilterType = FilterType, TAbiEvent extends AbiEvent | undefined = undefined, TAbi extends Abi | readonly unknown[] = [TAbiEvent], TEventName extends string | undefined = MaybeAbiEventName<TAbiEvent>> = TFilterType extends 'event' ? Log<bigint, number, TAbiEvent, TAbi, TEventName>[] : Hash[];
276
- declare function getFilterChanges<TFilterType extends FilterType, TAbiEvent extends AbiEvent | undefined, TAbi extends Abi | readonly unknown[], TEventName extends string | undefined>(client: PublicClient, { filter, }: GetFilterChangesParameters<TFilterType, TAbiEvent, TAbi, TEventName>): Promise<GetFilterChangesReturnType<TFilterType, TAbiEvent, TAbi, TEventName>>;
330
+ declare function getFilterChanges<TFilterType extends FilterType, TAbiEvent extends AbiEvent | undefined, TAbi extends Abi | readonly unknown[], TEventName extends string | undefined>(client: PublicClientArg, { filter, }: GetFilterChangesParameters<TFilterType, TAbiEvent, TAbi, TEventName>): Promise<GetFilterChangesReturnType<TFilterType, TAbiEvent, TAbi, TEventName>>;
277
331
 
278
332
  type GetFilterLogsParameters<TAbiEvent extends AbiEvent | undefined = undefined, TAbi extends Abi | readonly unknown[] = [TAbiEvent], TEventName extends string | undefined = MaybeAbiEventName<TAbiEvent>> = {
279
333
  filter: Filter<'event', TAbi, TEventName, any>;
280
334
  };
281
335
  type GetFilterLogsReturnType<TAbiEvent extends AbiEvent | undefined = undefined, TAbi extends Abi | readonly unknown[] = [TAbiEvent], TEventName extends string | undefined = MaybeAbiEventName<TAbiEvent>> = Log<bigint, number, TAbiEvent, TAbi, TEventName>[];
282
- declare function getFilterLogs<TAbiEvent extends AbiEvent | undefined, TAbi extends Abi | readonly unknown[], TEventName extends string | undefined>(client: PublicClient, { filter }: GetFilterLogsParameters<TAbiEvent, TAbi, TEventName>): Promise<GetFilterLogsReturnType<TAbiEvent, TAbi, TEventName>>;
336
+ declare function getFilterLogs<TAbiEvent extends AbiEvent | undefined, TAbi extends Abi | readonly unknown[], TEventName extends string | undefined>(client: PublicClientArg, { filter }: GetFilterLogsParameters<TAbiEvent, TAbi, TEventName>): Promise<GetFilterLogsReturnType<TAbiEvent, TAbi, TEventName>>;
283
337
 
284
338
  type GetGasPriceReturnType = bigint;
285
339
  /**
286
340
  * @description Returns the current price of gas (in wei).
287
341
  */
288
- declare function getGasPrice(client: PublicClient | WalletClient): Promise<GetGasPriceReturnType>;
342
+ declare function getGasPrice(client: PublicClientArg | WalletClientArg): Promise<GetGasPriceReturnType>;
289
343
 
290
344
  type GetLogsParameters<TAbiEvent extends AbiEvent | undefined = undefined, TEventName extends string | undefined = MaybeAbiEventName<TAbiEvent>> = {
291
345
  /** Address or list of addresses from which logs originated */
@@ -312,7 +366,7 @@ type GetLogsReturnType<TAbiEvent extends AbiEvent | undefined = undefined, TEven
312
366
  /**
313
367
  * @description Returns a collection of event logs.
314
368
  */
315
- declare function getLogs<TAbiEvent extends AbiEvent | undefined>(client: PublicClient, { address, blockHash, fromBlock, toBlock, event, args, }?: GetLogsParameters<TAbiEvent>): Promise<GetLogsReturnType<TAbiEvent>>;
369
+ declare function getLogs<TAbiEvent extends AbiEvent | undefined>(client: PublicClientArg, { address, blockHash, fromBlock, toBlock, event, args, }?: GetLogsParameters<TAbiEvent>): Promise<GetLogsReturnType<TAbiEvent>>;
316
370
 
317
371
  type GetStorageAtParameters = {
318
372
  address: Address;
@@ -325,7 +379,7 @@ type GetStorageAtParameters = {
325
379
  blockTag?: never;
326
380
  });
327
381
  type GetStorageAtReturnType = Hex | undefined;
328
- declare function getStorageAt(client: PublicClient, { address, blockNumber, blockTag, slot }: GetStorageAtParameters): Promise<GetStorageAtReturnType>;
382
+ declare function getStorageAt(client: PublicClientArg, { address, blockNumber, blockTag, slot }: GetStorageAtParameters): Promise<GetStorageAtReturnType>;
329
383
 
330
384
  type GetTransactionParameters = {
331
385
  /** The block hash */
@@ -359,11 +413,11 @@ type GetTransactionParameters = {
359
413
  hash: Hash;
360
414
  index?: number;
361
415
  };
362
- type GetTransactionReturnType<TChain extends Chain = Chain> = FormattedTransaction<TransactionFormatter<TChain>>;
416
+ type GetTransactionReturnType<TChain extends Chain | undefined = Chain> = FormattedTransaction<TransactionFormatter<TChain>>;
363
417
  /** @description Returns information about a transaction given a hash or block identifier. */
364
- declare function getTransaction<TChain extends Chain>(client: PublicClient<any, TChain>, { blockHash, blockNumber, blockTag, hash, index, }: GetTransactionParameters): Promise<GetTransactionReturnType<TChain>>;
418
+ declare function getTransaction<TChain extends Chain | undefined>(client: PublicClientArg<Transport, TChain>, { blockHash, blockNumber, blockTag, hash, index, }: GetTransactionParameters): Promise<GetTransactionReturnType<TChain>>;
365
419
 
366
- type GetTransactionConfirmationsParameters<TChain extends Chain = Chain> = {
420
+ type GetTransactionConfirmationsParameters<TChain extends Chain | undefined = Chain> = {
367
421
  /** The transaction hash. */
368
422
  hash: Hash;
369
423
  transactionReceipt?: never;
@@ -373,7 +427,7 @@ type GetTransactionConfirmationsParameters<TChain extends Chain = Chain> = {
373
427
  transactionReceipt: FormattedTransactionReceipt<TransactionReceiptFormatter<TChain>>;
374
428
  };
375
429
  type GetTransactionConfirmationsReturnType = bigint;
376
- declare function getTransactionConfirmations<TChain extends Chain>(client: PublicClient<any, TChain>, { hash, transactionReceipt }: GetTransactionConfirmationsParameters<TChain>): Promise<GetTransactionConfirmationsReturnType>;
430
+ declare function getTransactionConfirmations<TChain extends Chain | undefined>(client: PublicClientArg<Transport, TChain>, { hash, transactionReceipt }: GetTransactionConfirmationsParameters<TChain>): Promise<GetTransactionConfirmationsReturnType>;
377
431
 
378
432
  type GetTransactionCountParameters = {
379
433
  /** The account address. */
@@ -391,14 +445,14 @@ type GetTransactionCountReturnType = number;
391
445
  /**
392
446
  * @description Returns the number of transactions an account has broadcast / sent.
393
447
  */
394
- declare function getTransactionCount(client: PublicClient | WalletClient, { address, blockTag, blockNumber }: GetTransactionCountParameters): Promise<GetTransactionCountReturnType>;
448
+ declare function getTransactionCount(client: PublicClientArg | WalletClientArg, { address, blockTag, blockNumber }: GetTransactionCountParameters): Promise<GetTransactionCountReturnType>;
395
449
 
396
450
  type GetTransactionReceiptParameters = {
397
451
  /** The hash of the transaction. */
398
452
  hash: Hash;
399
453
  };
400
- type GetTransactionReceiptReturnType<TChain extends Chain = Chain> = FormattedTransactionReceipt<TransactionReceiptFormatter<TChain>>;
401
- declare function getTransactionReceipt<TChain extends Chain>(client: PublicClient<any, TChain>, { hash }: GetTransactionReceiptParameters): Promise<Formatted<ExtractFormatter<TChain, "transactionReceipt", Formatter<RpcTransactionReceipt, TransactionReceipt<bigint, number, "success" | "reverted", TransactionType>>>, TransactionReceipt<bigint, number, "success" | "reverted", TransactionType>, false, false>>;
454
+ type GetTransactionReceiptReturnType<TChain extends Chain | undefined = Chain> = FormattedTransactionReceipt<TransactionReceiptFormatter<TChain>>;
455
+ declare function getTransactionReceipt<TChain extends Chain | undefined>(client: PublicClientArg<Transport, TChain>, { hash }: GetTransactionReceiptParameters): Promise<Formatted<TransactionReceiptFormatter<TChain>, TransactionReceipt<bigint, number, "success" | "reverted", TransactionType>, false, false>>;
402
456
 
403
457
  type MAXIMUM_DEPTH = 20;
404
458
  type Contract<TAbi extends Abi | readonly unknown[] = Abi | readonly unknown[], TFunctionName extends string = string> = {
@@ -448,27 +502,27 @@ type MulticallParameters<TContracts extends ContractConfig[] = ContractConfig[],
448
502
  multicallAddress?: Address;
449
503
  };
450
504
  type MulticallReturnType<TContracts extends ContractConfig[] = ContractConfig[], TAllowFailure extends boolean = true> = MulticallResults<TContracts, TAllowFailure>;
451
- declare function multicall<TContracts extends ContractConfig[], TAllowFailure extends boolean = true>(client: PublicClient, args: MulticallParameters<TContracts, TAllowFailure>): Promise<MulticallReturnType<TContracts, TAllowFailure>>;
505
+ declare function multicall<TContracts extends ContractConfig[], TAllowFailure extends boolean = true>(client: PublicClientArg, args: MulticallParameters<TContracts, TAllowFailure>): Promise<MulticallReturnType<TContracts, TAllowFailure>>;
452
506
 
453
507
  type ReadContractParameters<TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = string> = Pick<CallParameters, 'blockNumber' | 'blockTag'> & ContractConfig<TAbi, TFunctionName, 'view' | 'pure'>;
454
508
  type ReadContractReturnType<TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = string> = ExtractResultFromAbi<TAbi, TFunctionName>;
455
- declare function readContract<TAbi extends Abi | readonly unknown[], TFunctionName extends string>(client: PublicClient, { abi, address, args, functionName, ...callRequest }: ReadContractParameters<TAbi, TFunctionName>): Promise<ReadContractReturnType<TAbi, TFunctionName>>;
509
+ declare function readContract<TAbi extends Abi | readonly unknown[], TFunctionName extends string>(client: PublicClientArg, { abi, address, args, functionName, ...callRequest }: ReadContractParameters<TAbi, TFunctionName>): Promise<ReadContractReturnType<TAbi, TFunctionName>>;
456
510
 
457
511
  type UninstallFilterParameters = {
458
512
  filter: Filter<any>;
459
513
  };
460
514
  type UninstallFilterReturnType = boolean;
461
- declare function uninstallFilter(client: PublicClient, { filter }: UninstallFilterParameters): Promise<UninstallFilterReturnType>;
515
+ declare function uninstallFilter(client: PublicClientArg, { filter }: UninstallFilterParameters): Promise<UninstallFilterReturnType>;
462
516
 
463
517
  type ReplacementReason = 'cancelled' | 'replaced' | 'repriced';
464
- type ReplacementReturnType<TChain extends Chain = Chain> = {
518
+ type ReplacementReturnType<TChain extends Chain | undefined = Chain> = {
465
519
  reason: ReplacementReason;
466
520
  replacedTransaction: Transaction;
467
521
  transaction: Transaction;
468
522
  transactionReceipt: GetTransactionReceiptReturnType<TChain>;
469
523
  };
470
- type WaitForTransactionReceiptReturnType<TChain extends Chain = Chain> = GetTransactionReceiptReturnType<TChain>;
471
- type WaitForTransactionReceiptParameters<TChain extends Chain = Chain> = {
524
+ type WaitForTransactionReceiptReturnType<TChain extends Chain | undefined = Chain> = GetTransactionReceiptReturnType<TChain>;
525
+ type WaitForTransactionReceiptParameters<TChain extends Chain | undefined = Chain> = {
472
526
  /** The number of confirmations (blocks that have passed) to wait before resolving. */
473
527
  confirmations?: number;
474
528
  /** The hash of the transaction. */
@@ -479,7 +533,7 @@ type WaitForTransactionReceiptParameters<TChain extends Chain = Chain> = {
479
533
  /** Optional timeout (in milliseconds) to wait before stopping polling. */
480
534
  timeout?: number;
481
535
  };
482
- declare function waitForTransactionReceipt<TChain extends Chain>(client: PublicClient<any, TChain>, { confirmations, hash, onReplaced, pollingInterval, timeout, }: WaitForTransactionReceiptParameters<TChain>): Promise<WaitForTransactionReceiptReturnType<TChain>>;
536
+ declare function waitForTransactionReceipt<TChain extends Chain | undefined>(client: PublicClientArg<Transport, TChain>, { confirmations, hash, onReplaced, pollingInterval, timeout, }: WaitForTransactionReceiptParameters<TChain>): Promise<WaitForTransactionReceiptReturnType<TChain>>;
483
537
 
484
538
  type OnBlockNumberParameter = GetBlockNumberReturnType;
485
539
  type OnBlockNumberFn = (blockNumber: OnBlockNumberParameter, prevBlockNumber: OnBlockNumberParameter | undefined) => void;
@@ -496,11 +550,11 @@ type WatchBlockNumberParameters = {
496
550
  pollingInterval?: number;
497
551
  };
498
552
  /** @description Watches and returns incoming block numbers. */
499
- declare function watchBlockNumber(client: PublicClient<any, any, any>, { emitOnBegin, emitMissed, onBlockNumber, onError, pollingInterval, }: WatchBlockNumberParameters): () => void;
553
+ declare function watchBlockNumber(client: PublicClientArg, { emitOnBegin, emitMissed, onBlockNumber, onError, pollingInterval, }: WatchBlockNumberParameters): () => void;
500
554
 
501
- type OnBlockParameter<TChain extends Chain = Chain, TIncludeTransactions = false> = Omit<GetBlockReturnType<TChain>, TIncludeTransactions extends false ? 'transactions' : ''>;
502
- type OnBlock<TChain extends Chain = Chain, TIncludeTransactions = false> = (block: OnBlockParameter<TChain, TIncludeTransactions>, prevBlock: OnBlockParameter<TChain, TIncludeTransactions> | undefined) => void;
503
- type WatchBlocksParameters<TChain extends Chain = Chain> = {
555
+ type OnBlockParameter<TChain extends Chain | undefined = Chain, TIncludeTransactions = false> = Omit<GetBlockReturnType<TChain>, TIncludeTransactions extends false ? 'transactions' : ''>;
556
+ type OnBlock<TChain extends Chain | undefined = Chain, TIncludeTransactions = false> = (block: OnBlockParameter<TChain, TIncludeTransactions>, prevBlock: OnBlockParameter<TChain, TIncludeTransactions> | undefined) => void;
557
+ type WatchBlocksParameters<TChain extends Chain | undefined = Chain> = {
504
558
  /** The block tag. Defaults to "latest". */
505
559
  blockTag?: BlockTag;
506
560
  /** Whether or not to emit the missed blocks to the callback. */
@@ -523,7 +577,7 @@ type WatchBlocksParameters<TChain extends Chain = Chain> = {
523
577
  onBlock: OnBlock<TChain>;
524
578
  });
525
579
  /** @description Watches and returns information for incoming blocks. */
526
- declare function watchBlocks<TChain extends Chain, TWatchBlocksParameters extends WatchBlocksParameters<TChain>>(client: PublicClient<any, TChain>, { blockTag, emitMissed, emitOnBegin, onBlock, onError, includeTransactions, pollingInterval, }: TWatchBlocksParameters): () => void;
580
+ declare function watchBlocks<TChain extends Chain | undefined, TWatchBlocksParameters extends WatchBlocksParameters<TChain>>(client: PublicClientArg<Transport, TChain>, { blockTag, emitMissed, emitOnBegin, onBlock, onError, includeTransactions, pollingInterval, }: TWatchBlocksParameters): () => void;
527
581
 
528
582
  type OnLogsParameter$1<TAbi extends Abi | readonly unknown[] = readonly unknown[], TEventName extends string = string> = TAbi extends Abi ? Log<bigint, number, ExtractAbiEvent<TAbi, TEventName>>[] : Log[];
529
583
  type OnLogsFn$1<TAbi extends Abi | readonly unknown[] = readonly unknown[], TEventName extends string = string> = (logs: OnLogsParameter$1<TAbi, TEventName>) => void;
@@ -544,7 +598,7 @@ type WatchContractEventParameters<TAbi extends Abi | readonly unknown[] = readon
544
598
  /** Polling frequency (in ms). Defaults to Client's pollingInterval config. */
545
599
  pollingInterval?: number;
546
600
  };
547
- declare function watchContractEvent<TAbi extends Abi | readonly unknown[], TEventName extends string>(client: PublicClient, { abi, address, args, batch, eventName, onError, onLogs, pollingInterval, }: WatchContractEventParameters<TAbi, TEventName>): () => void;
601
+ declare function watchContractEvent<TAbi extends Abi | readonly unknown[], TEventName extends string>(client: PublicClientArg, { abi, address, args, batch, eventName, onError, onLogs, pollingInterval, }: WatchContractEventParameters<TAbi, TEventName>): () => void;
548
602
 
549
603
  type OnLogsParameter<TAbiEvent extends AbiEvent | undefined = undefined, TEventName extends string | undefined = MaybeAbiEventName<TAbiEvent>> = Log<bigint, number, TAbiEvent, [TAbiEvent], TEventName>[];
550
604
  type OnLogsFn<TAbiEvent extends AbiEvent | undefined = undefined, TEventName extends string | undefined = MaybeAbiEventName<TAbiEvent>> = (logs: OnLogsParameter<TAbiEvent, TEventName>) => void;
@@ -566,7 +620,7 @@ type WatchEventParameters<TAbiEvent extends AbiEvent | undefined = undefined, TE
566
620
  event?: never;
567
621
  args?: never;
568
622
  });
569
- declare function watchEvent<TAbiEvent extends AbiEvent | undefined, TEventName extends string | undefined>(client: PublicClient, { address, args, batch, event, onError, onLogs, pollingInterval, }: WatchEventParameters<TAbiEvent>): () => void;
623
+ declare function watchEvent<TAbiEvent extends AbiEvent | undefined, TEventName extends string | undefined>(client: PublicClientArg, { address, args, batch, event, onError, onLogs, pollingInterval, }: WatchEventParameters<TAbiEvent>): () => void;
570
624
 
571
625
  type OnTransactionsParameter = Hash[];
572
626
  type OnTransactionsFn = (transactions: OnTransactionsParameter) => void;
@@ -580,119 +634,7 @@ type WatchPendingTransactionsParameters = {
580
634
  /** Polling frequency (in ms). Defaults to Client's pollingInterval config. */
581
635
  pollingInterval?: number;
582
636
  };
583
- declare function watchPendingTransactions(client: PublicClient, { batch, onError, onTransactions, pollingInterval, }: WatchPendingTransactionsParameters): () => void;
584
-
585
- type GetPermissionsReturnType = WalletPermission[];
586
- declare function getPermissions(client: WalletClient): Promise<WalletPermission[]>;
587
-
588
- type RequestAddressesReturnType = Address[];
589
- declare function requestAddresses(client: WalletClient): Promise<RequestAddressesReturnType>;
590
-
591
- type RequestPermissionsParameters = {
592
- eth_accounts: Record<string, any>;
593
- } & {
594
- [key: string]: Record<string, any>;
595
- };
596
- type RequestPermissionsReturnType = WalletPermission[];
597
- declare function requestPermissions(client: WalletClient, permissions: RequestPermissionsParameters): Promise<WalletPermission[]>;
598
-
599
- type FormattedTransactionRequest<TFormatter extends Formatter | undefined = Formatter> = MergeIntersectionProperties<Omit<Formatted<TFormatter, TransactionRequest, true>, 'from'>, TransactionRequest>;
600
- type SendTransactionParameters<TChain extends Chain = Chain> = FormattedTransactionRequest<TransactionRequestFormatter<TChain>> & {
601
- account: Account;
602
- } & ({
603
- assertChain?: false;
604
- chain?: TChain;
605
- } | {
606
- assertChain: true;
607
- chain: TChain;
608
- });
609
- type SendTransactionReturnType = Hash;
610
- declare function sendTransaction<TChain extends Chain>(client: WalletClient<any, any>, args: SendTransactionParameters<TChain>): Promise<SendTransactionReturnType>;
611
-
612
- type SignMessageParameters = {
613
- account: Account;
614
- } & ({
615
- /** @deprecated – `data` will be removed in 0.2.0; use `message` instead. */
616
- data: string;
617
- message?: never;
618
- } | {
619
- data?: never;
620
- message: string;
621
- });
622
- type SignMessageReturnType = Hex;
623
- declare function signMessage(client: WalletClient, { account, data, message }: SignMessageParameters): Promise<SignMessageReturnType>;
624
-
625
- type SignTypedDataParameters<TTypedData extends TypedData | {
626
- [key: string]: unknown;
627
- } = TypedData, TPrimaryType extends string = string> = {
628
- account: Account;
629
- } & TypedDataDefinition<TTypedData, TPrimaryType>;
630
- type TypedDataDefinition<TTypedData extends TypedData | {
631
- [key: string]: unknown;
632
- } = TypedData, TPrimaryType extends string = string> = {
633
- domain?: TypedDataDomain;
634
- types: Narrow<TTypedData>;
635
- primaryType: GetPrimaryType<TTypedData, TPrimaryType>;
636
- } & GetMessage<TTypedData, TPrimaryType>;
637
- type GetPrimaryType<TTypedData extends TypedData | {
638
- [key: string]: unknown;
639
- } = TypedData, TPrimaryType extends string = string> = TTypedData extends TypedData ? keyof TTypedData extends infer AbiFunctionNames ? AbiFunctionNames | (TPrimaryType extends AbiFunctionNames ? TPrimaryType : never) | (TypedData extends TTypedData ? string : never) : never : TPrimaryType;
640
- type GetMessage<TTypedData extends TypedData | {
641
- [key: string]: unknown;
642
- } = TypedData, TPrimaryType extends string = string, TSchema = TTypedData extends TypedData ? TypedDataToPrimitiveTypes<TTypedData> : {
643
- [key: string]: any;
644
- }, TMessage = TSchema[TPrimaryType extends keyof TSchema ? TPrimaryType : keyof TSchema]> = {
645
- [key: string]: any;
646
- } extends TMessage ? {
647
- /**
648
- * Data to sign
649
- *
650
- * Use a [const assertion](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-4.html#const-assertions) on {@link types} for type inference.
651
- */
652
- message: {
653
- [key: string]: unknown;
654
- };
655
- } : {
656
- /** Data to sign */
657
- message: TMessage;
658
- };
659
- type SignTypedDataReturnType = Hex;
660
- declare function signTypedData<TTypedData extends TypedData | {
661
- [key: string]: unknown;
662
- }, TPrimaryType extends string = string>(client: WalletClient, { account, domain, message, primaryType, types: types_, }: SignTypedDataParameters<TTypedData, TPrimaryType>): Promise<SignTypedDataReturnType>;
663
-
664
- type SwitchChainParameters = {
665
- id: Chain['id'];
666
- };
667
- declare function switchChain(client: WalletClient, { id }: SwitchChainParameters): Promise<void>;
668
-
669
- type WatchAssetParameters = WatchAssetParams;
670
- type WatchAssetReturnType = boolean;
671
- declare function watchAsset(client: WalletClient, params: WatchAssetParameters): Promise<WatchAssetReturnType>;
672
-
673
- type WriteContractParameters<TChain extends Chain = Chain, TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = string> = Omit<SendTransactionParameters<TChain>, 'to' | 'data' | 'value'> & {
674
- value?: GetValue<TAbi, TFunctionName, SendTransactionParameters<TChain>['value']>;
675
- } & ContractConfig<TAbi, TFunctionName, 'payable' | 'nonpayable'>;
676
- type WriteContractReturnType = SendTransactionReturnType;
677
- declare function writeContract<TChain extends Chain, TAbi extends Abi | readonly unknown[], TFunctionName extends string>(client: WalletClient, { abi, address, args, functionName, ...request }: WriteContractParameters<TChain, TAbi, TFunctionName>): Promise<WriteContractReturnType>;
678
-
679
- type Account = JsonRpcAccount | LocalAccount;
680
- type JsonRpcAccount = {
681
- address: Address;
682
- type: 'json-rpc';
683
- };
684
- type LocalAccount = {
685
- address: Address;
686
- signMessage: (message: string) => Promise<Hash>;
687
- signTransaction: (transaction: Omit<TransactionRequest, 'from'> & {
688
- chainId: number;
689
- from: Address;
690
- }) => Promise<Hash>;
691
- signTypedData: <TTypedData extends TypedData | {
692
- [key: string]: unknown;
693
- }, TPrimaryType extends string = string>(typedData: TypedDataDefinition<TTypedData, TPrimaryType>) => Promise<Hash>;
694
- type: 'local';
695
- };
637
+ declare function watchPendingTransactions(client: PublicClientArg, { batch, onError, onTransactions, pollingInterval, }: WatchPendingTransactionsParameters): () => void;
696
638
 
697
639
  type FilterType = 'transaction' | 'block' | 'event';
698
640
  type Filter<TFilterType extends FilterType = 'event', TAbi extends Abi | readonly unknown[] = Abi, TEventName extends string | undefined = undefined, TArgs extends MaybeExtractEventArgsFromAbi<TAbi, TEventName> | undefined = MaybeExtractEventArgsFromAbi<TAbi, TEventName>> = {
@@ -737,7 +679,7 @@ type GetEnsAddressReturnType = Address;
737
679
  * })
738
680
  * // '0xd2135CfB216b74109775236E36d4b433F1DF507B'
739
681
  */
740
- declare function getEnsAddress(client: PublicClient, { blockNumber, blockTag, name, universalResolverAddress: universalResolverAddress_, }: GetEnsAddressParameters): Promise<GetEnsAddressReturnType>;
682
+ declare function getEnsAddress(client: PublicClientArg, { blockNumber, blockTag, name, universalResolverAddress: universalResolverAddress_, }: GetEnsAddressParameters): Promise<GetEnsAddressReturnType>;
741
683
 
742
684
  type GetEnsNameParameters = Prettify<Pick<ReadContractParameters, 'blockNumber' | 'blockTag'> & {
743
685
  /** Address to get ENS name for. */
@@ -757,15 +699,15 @@ type GetEnsNameReturnType = string | null;
757
699
  * })
758
700
  * // 'wagmi-dev.eth'
759
701
  */
760
- declare function getEnsName(client: PublicClient, { address, blockNumber, blockTag, universalResolverAddress: universalResolverAddress_, }: GetEnsNameParameters): Promise<GetEnsNameReturnType>;
702
+ declare function getEnsName(client: PublicClientArg, { address, blockNumber, blockTag, universalResolverAddress: universalResolverAddress_, }: GetEnsNameParameters): Promise<GetEnsNameReturnType>;
761
703
 
762
- type PublicActions<TChain extends Chain = Chain> = {
704
+ type PublicActions<TChain extends Chain | undefined = Chain> = {
763
705
  call: (args: CallParameters<TChain>) => Promise<CallReturnType>;
764
706
  createBlockFilter: () => Promise<CreateBlockFilterReturnType>;
765
707
  createContractEventFilter: <TAbi extends Abi | readonly unknown[], TEventName extends string | undefined, TArgs extends MaybeExtractEventArgsFromAbi<TAbi, TEventName> | undefined>(args: CreateContractEventFilterParameters<TAbi, TEventName, TArgs>) => Promise<CreateContractEventFilterReturnType<TAbi, TEventName, TArgs>>;
766
708
  createEventFilter: <TAbiEvent extends AbiEvent | undefined, TAbi extends Abi | readonly unknown[], TEventName extends string | undefined, TArgs extends MaybeExtractEventArgsFromAbi<TAbi, TEventName> | undefined>(args?: CreateEventFilterParameters<TAbiEvent, TAbi, TEventName, TArgs>) => Promise<CreateEventFilterReturnType<TAbiEvent, TAbi, TEventName, TArgs>>;
767
709
  createPendingTransactionFilter: () => Promise<CreatePendingTransactionFilterReturnType>;
768
- estimateContractGas: <TChain extends Chain, TAbi extends Abi | readonly unknown[], TFunctionName extends string>(args: EstimateContractGasParameters<TChain, TAbi, TFunctionName>) => Promise<EstimateContractGasReturnType>;
710
+ estimateContractGas: <TChain extends Chain | undefined, TAbi extends Abi | readonly unknown[], TFunctionName extends string>(args: EstimateContractGasParameters<TChain, TAbi, TFunctionName>) => Promise<EstimateContractGasReturnType>;
769
711
  estimateGas: (args: EstimateGasParameters<TChain>) => Promise<EstimateGasReturnType>;
770
712
  getBalance: (args: GetBalanceParameters) => Promise<GetBalanceReturnType>;
771
713
  getBlock: (args?: GetBlockParameters) => Promise<GetBlockReturnType<TChain>>;
@@ -787,7 +729,7 @@ type PublicActions<TChain extends Chain = Chain> = {
787
729
  getTransactionReceipt: (args: GetTransactionReceiptParameters) => Promise<GetTransactionReceiptReturnType<TChain>>;
788
730
  multicall: <TContracts extends ContractConfig[], TAllowFailure extends boolean = true>(args: MulticallParameters<TContracts, TAllowFailure>) => Promise<MulticallReturnType<TContracts, TAllowFailure>>;
789
731
  readContract: <TAbi extends Abi | readonly unknown[], TFunctionName extends string>(args: ReadContractParameters<TAbi, TFunctionName>) => Promise<ReadContractReturnType<TAbi, TFunctionName>>;
790
- simulateContract: <TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = any, TChainOverride extends Chain | undefined = undefined>(args: SimulateContractParameters<TChain, TAbi, TFunctionName, TChainOverride>) => Promise<SimulateContractReturnType<TChainOverride extends Chain ? TChainOverride : TChain, TAbi, TFunctionName>>;
732
+ simulateContract: <TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = any, TChainOverride extends Chain | undefined = undefined>(args: SimulateContractParameters<TChain, TAbi, TFunctionName, TChainOverride>) => Promise<SimulateContractReturnType<TChain, TAbi, TFunctionName, TChainOverride>>;
791
733
  uninstallFilter: (args: UninstallFilterParameters) => Promise<UninstallFilterReturnType>;
792
734
  waitForTransactionReceipt: (args: WaitForTransactionReceiptParameters<TChain>) => Promise<WaitForTransactionReceiptReturnType<TChain>>;
793
735
  watchBlockNumber: (args: WatchBlockNumberParameters) => ReturnType<typeof watchBlockNumber>;
@@ -797,8 +739,9 @@ type PublicActions<TChain extends Chain = Chain> = {
797
739
  watchPendingTransactions: (args: WatchPendingTransactionsParameters) => ReturnType<typeof watchPendingTransactions>;
798
740
  };
799
741
 
800
- type WalletClientConfig<TTransport extends Transport = Transport, TChain extends Chain = Chain> = {
801
- chain?: ClientConfig<TTransport, TChain>['chain'];
742
+ type WalletClientConfig<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain, TAccount extends Account | Address | undefined = undefined> = {
743
+ account?: TAccount;
744
+ chain?: TChain;
802
745
  /** The key of the Wallet Client. */
803
746
  key?: ClientConfig['key'];
804
747
  /** The name of the Wallet Client. */
@@ -807,35 +750,39 @@ type WalletClientConfig<TTransport extends Transport = Transport, TChain extends
807
750
  pollingInterval?: ClientConfig['pollingInterval'];
808
751
  transport: ClientConfig<TTransport, TChain>['transport'];
809
752
  };
810
- type WalletClient<TTransport extends Transport = Transport, TChain extends Chain = Chain, TIncludeActions extends boolean = true> = Client<TTransport, TChain> & (TIncludeActions extends true ? WalletActions<TChain> : {});
753
+ type WalletClient<TTransport extends Transport = Transport, TChain extends Chain | undefined = undefined, TAccount extends Account | undefined = undefined, TIncludeActions extends boolean = true> = Client<TTransport, TChain> & {
754
+ account: TAccount;
755
+ } & (TIncludeActions extends true ? WalletActions<TChain, TAccount> : {});
756
+ type WalletClientArg<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TAccount extends Account | undefined = Account | undefined, TIncludeActions extends boolean = boolean> = WalletClient<TTransport, TChain, TAccount, TIncludeActions>;
811
757
  /**
812
758
  * @description Creates a wallet client with a given transport.
813
759
  */
814
- declare function createWalletClient<TTransport extends Transport, TChain extends Chain>({ chain, transport, key, name, pollingInterval, }: WalletClientConfig<TTransport, TChain>): WalletClient<TTransport, TChain, true>;
760
+ declare function createWalletClient<TTransport extends Transport, TChain extends Chain | undefined = undefined, TAccountOrAddress extends Account | Address | undefined = undefined, TAccount extends Account | undefined = ParseAccount<TAccountOrAddress>>({ account, chain, transport, key, name, pollingInterval, }: WalletClientConfig<TTransport, TChain, TAccountOrAddress>): WalletClient<TTransport, TChain, TAccount, true>;
815
761
 
816
- type WalletActions<TChain extends Chain = Chain> = {
762
+ type WalletActions<TChain extends Chain | undefined = Chain, TAccount extends Account | undefined = undefined> = {
817
763
  addChain: (args: AddChainParameters) => Promise<void>;
818
- deployContract: <TAbi extends Abi | readonly unknown[]>(args: DeployContractParameters<TChain, TAbi>) => Promise<DeployContractReturnType>;
764
+ deployContract: <TAbi extends Abi | readonly unknown[], TChainOverride extends Chain | undefined>(args: DeployContractParameters<TChain, TAbi, TAccount, TChainOverride>) => Promise<DeployContractReturnType>;
819
765
  getAddresses: () => Promise<GetAddressesReturnType>;
820
766
  getChainId: () => Promise<GetChainIdReturnType>;
821
767
  getPermissions: () => Promise<GetPermissionsReturnType>;
822
768
  requestAddresses: () => Promise<RequestAddressesReturnType>;
823
769
  requestPermissions: (args: RequestPermissionsParameters) => Promise<RequestPermissionsReturnType>;
824
- sendTransaction: <TChainOverride extends Chain>(args: SendTransactionParameters<TChainOverride>) => Promise<SendTransactionReturnType>;
825
- signMessage: (args: SignMessageParameters) => Promise<SignMessageReturnType>;
770
+ sendTransaction: <TChainOverride extends Chain | undefined>(args: SendTransactionParameters<TChain, TAccount, TChainOverride>) => Promise<SendTransactionReturnType>;
771
+ signMessage: (args: SignMessageParameters<TAccount>) => Promise<SignMessageReturnType>;
826
772
  signTypedData: <TTypedData extends TypedData | {
827
773
  [key: string]: unknown;
828
- }>(args: SignTypedDataParameters<TTypedData>) => Promise<SignTypedDataReturnType>;
774
+ }, TPrimaryType extends string = string>(args: SignTypedDataParameters<TTypedData, TPrimaryType, TAccount>) => Promise<SignTypedDataReturnType>;
829
775
  switchChain: (args: SwitchChainParameters) => Promise<void>;
830
776
  watchAsset: (args: WatchAssetParameters) => Promise<WatchAssetReturnType>;
831
- writeContract: <TAbi extends Abi | readonly unknown[], TFunctionName extends string, TChainOverride extends Chain>(args: WriteContractParameters<TChainOverride, TAbi, TFunctionName>) => Promise<WriteContractReturnType>;
777
+ writeContract: <TAbi extends Abi | readonly unknown[], TFunctionName extends string, TChainOverride extends Chain | undefined>(args: WriteContractParameters<TChainOverride, TAbi, TFunctionName, TAccount, TChainOverride>) => Promise<WriteContractReturnType>;
832
778
  };
833
779
 
834
- type PublicClientConfig<TTransport extends Transport = Transport, TChain extends Chain = Chain> = Pick<ClientConfig<TTransport, TChain>, 'chain' | 'key' | 'name' | 'pollingInterval' | 'transport'>;
835
- type PublicClient<TTransport extends Transport = Transport, TChain extends Chain = Chain, TIncludeActions extends boolean = true> = Client<TTransport, TChain, PublicRequests> & (TIncludeActions extends true ? PublicActions<TChain> : {});
780
+ type PublicClientConfig<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain> = Pick<ClientConfig<TTransport, TChain>, 'chain' | 'key' | 'name' | 'pollingInterval' | 'transport'>;
781
+ type PublicClient<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain, TIncludeActions extends boolean = true> = Client<TTransport, TChain, PublicRequests> & (TIncludeActions extends true ? PublicActions<TChain> : {});
782
+ type PublicClientArg<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TIncludeActions extends boolean = boolean> = PublicClient<TTransport, TChain, TIncludeActions>;
836
783
  /**
837
784
  * @description Creates a public client with a given transport.
838
785
  */
839
- declare function createPublicClient<TTransport extends Transport, TChain extends Chain>({ chain, key, name, transport, pollingInterval, }: PublicClientConfig<TTransport, TChain>): PublicClient<TTransport, TChain, true>;
786
+ declare function createPublicClient<TTransport extends Transport, TChain extends Chain | undefined>({ chain, key, name, transport, pollingInterval, }: PublicClientConfig<TTransport, TChain>): PublicClient<TTransport, TChain, true>;
840
787
 
841
- export { writeContract as $, Account as A, BlockFormatter as B, CallParameters as C, estimateContractGas as D, EstimateGasParameters as E, FormattedBlock as F, GetBytecodeParameters as G, getBytecode as H, getStorageAt as I, JsonRpcAccount as J, multicall as K, LocalAccount as L, MulticallParameters as M, readContract as N, OnLogsFn as O, PublicClient as P, simulateContract as Q, ReadContractParameters as R, SendTransactionParameters as S, TransactionReceiptFormatter as T, watchContractEvent as U, DeployContractParameters as V, WalletClient as W, DeployContractReturnType as X, WriteContractParameters as Y, WriteContractReturnType as Z, deployContract as _, PublicClientConfig as a, OnTransactionsFn as a$, GetEnsAddressParameters as a0, GetEnsNameParameters as a1, getEnsAddress as a2, getEnsName as a3, call as a4, createBlockFilter as a5, createEventFilter as a6, createPendingTransactionFilter as a7, estimateGas as a8, getBalance as a9, GetBalanceParameters as aA, GetBalanceReturnType as aB, GetBlockParameters as aC, GetBlockNumberParameters as aD, GetBlockNumberReturnType as aE, GetBlockReturnType as aF, GetBlockTransactionCountParameters as aG, GetBlockTransactionCountReturnType as aH, GetFeeHistoryParameters as aI, GetFeeHistoryReturnType as aJ, GetFilterChangesParameters as aK, GetFilterChangesReturnType as aL, GetFilterLogsParameters as aM, GetFilterLogsReturnType as aN, GetGasPriceReturnType as aO, GetTransactionParameters as aP, GetTransactionConfirmationsParameters as aQ, GetTransactionConfirmationsReturnType as aR, GetTransactionCountParameters as aS, GetTransactionCountReturnType as aT, GetTransactionReceiptParameters as aU, GetTransactionReceiptReturnType as aV, GetTransactionReturnType as aW, OnBlock as aX, OnBlockNumberFn as aY, OnBlockNumberParameter as aZ, OnBlockParameter as a_, getBlock as aa, getBlockNumber as ab, getBlockNumberCache as ac, getBlockTransactionCount as ad, getChainId as ae, getFeeHistory as af, getFilterChanges as ag, getFilterLogs as ah, getLogs as ai, getGasPrice as aj, getTransaction as ak, getTransactionConfirmations as al, getTransactionCount as am, getTransactionReceipt as an, uninstallFilter as ao, waitForTransactionReceipt as ap, watchBlockNumber as aq, watchBlocks as ar, watchEvent as as, watchPendingTransactions as at, CallReturnType as au, CreateBlockFilterReturnType as av, CreateEventFilterParameters as aw, CreateEventFilterReturnType as ax, CreatePendingTransactionFilterReturnType as ay, EstimateGasReturnType as az, WalletClientConfig as b, OnTransactionsParameter as b0, ReplacementReason as b1, ReplacementReturnType as b2, UninstallFilterParameters as b3, UninstallFilterReturnType as b4, WaitForTransactionReceiptParameters as b5, WaitForTransactionReceiptReturnType as b6, WatchBlockNumberParameters as b7, WatchBlocksParameters as b8, WatchPendingTransactionsParameters as b9, addChain as ba, getAddresses as bb, getPermissions as bc, requestAddresses as bd, requestPermissions as be, sendTransaction as bf, signMessage as bg, signTypedData as bh, switchChain as bi, watchAsset as bj, AddChainParameters as bk, FormattedTransactionRequest as bl, GetPermissionsReturnType as bm, GetAddressesReturnType as bn, RequestAddressesReturnType as bo, RequestPermissionsReturnType as bp, SendTransactionReturnType as bq, SignMessageParameters as br, SignMessageReturnType as bs, SignTypedDataParameters as bt, SignTypedDataReturnType as bu, SwitchChainParameters as bv, WatchAssetParameters as bw, WatchAssetReturnType as bx, createPublicClient as c, createWalletClient as d, FormattedTransactionReceipt as e, FormattedTransactionRequest$1 as f, TransactionRequestFormatter as g, defineBlock as h, defineTransactionReceipt as i, defineTransactionRequest as j, formatBlock as k, formatTransactionRequest as l, CreateContractEventFilterParameters as m, CreateContractEventFilterReturnType as n, EstimateContractGasParameters as o, EstimateContractGasReturnType as p, GetBytecodeReturnType as q, GetStorageAtParameters as r, GetStorageAtReturnType as s, MulticallReturnType as t, OnLogsParameter as u, ReadContractReturnType as v, SimulateContractParameters as w, SimulateContractReturnType as x, WatchContractEventParameters as y, createContractEventFilter as z };
788
+ export { getEnsAddress as $, estimateContractGas as A, BlockFormatter as B, CallParameters as C, getBytecode as D, EstimateGasParameters as E, FormattedBlock as F, GetBytecodeParameters as G, getStorageAt as H, multicall as I, readContract as J, simulateContract as K, watchContractEvent as L, MulticallParameters as M, DeployContractParameters as N, OnLogsFn as O, PublicClient as P, DeployContractReturnType as Q, ReadContractParameters as R, SendTransactionParameters as S, TransactionReceiptFormatter as T, WriteContractParameters as U, WriteContractReturnType as V, WalletClient as W, deployContract as X, writeContract as Y, GetEnsAddressParameters as Z, GetEnsNameParameters as _, PublicClientConfig as a, ReplacementReturnType as a$, getEnsName as a0, call as a1, createBlockFilter as a2, createEventFilter as a3, createPendingTransactionFilter as a4, estimateGas as a5, getBalance as a6, getBlock as a7, getBlockNumber as a8, getBlockNumberCache as a9, GetBlockNumberParameters as aA, GetBlockNumberReturnType as aB, GetBlockReturnType as aC, GetBlockTransactionCountParameters as aD, GetBlockTransactionCountReturnType as aE, GetFeeHistoryParameters as aF, GetFeeHistoryReturnType as aG, GetFilterChangesParameters as aH, GetFilterChangesReturnType as aI, GetFilterLogsParameters as aJ, GetFilterLogsReturnType as aK, GetGasPriceReturnType as aL, GetTransactionParameters as aM, GetTransactionConfirmationsParameters as aN, GetTransactionConfirmationsReturnType as aO, GetTransactionCountParameters as aP, GetTransactionCountReturnType as aQ, GetTransactionReceiptParameters as aR, GetTransactionReceiptReturnType as aS, GetTransactionReturnType as aT, OnBlock as aU, OnBlockNumberFn as aV, OnBlockNumberParameter as aW, OnBlockParameter as aX, OnTransactionsFn as aY, OnTransactionsParameter as aZ, ReplacementReason as a_, getBlockTransactionCount as aa, getChainId as ab, getFeeHistory as ac, getFilterChanges as ad, getFilterLogs as ae, getLogs as af, getGasPrice as ag, getTransaction as ah, getTransactionConfirmations as ai, getTransactionCount as aj, getTransactionReceipt as ak, uninstallFilter as al, waitForTransactionReceipt as am, watchBlockNumber as an, watchBlocks as ao, watchEvent as ap, watchPendingTransactions as aq, CallReturnType as ar, CreateBlockFilterReturnType as as, CreateEventFilterParameters as at, CreateEventFilterReturnType as au, CreatePendingTransactionFilterReturnType as av, EstimateGasReturnType as aw, GetBalanceParameters as ax, GetBalanceReturnType as ay, GetBlockParameters as az, WalletClientConfig as b, UninstallFilterParameters as b0, UninstallFilterReturnType as b1, WaitForTransactionReceiptParameters as b2, WaitForTransactionReceiptReturnType as b3, WatchBlockNumberParameters as b4, WatchBlocksParameters as b5, WatchPendingTransactionsParameters as b6, WalletClientArg as b7, PublicClientArg as b8, addChain as b9, getAddresses as ba, getPermissions as bb, requestAddresses as bc, requestPermissions as bd, sendTransaction as be, signMessage as bf, signTypedData as bg, switchChain as bh, watchAsset as bi, AddChainParameters as bj, FormattedTransactionRequest as bk, GetPermissionsReturnType as bl, GetAddressesReturnType as bm, RequestAddressesReturnType as bn, RequestPermissionsReturnType as bo, SendTransactionReturnType as bp, SignMessageParameters as bq, SignMessageReturnType as br, SignTypedDataParameters as bs, SignTypedDataReturnType as bt, SwitchChainParameters as bu, WatchAssetParameters as bv, WatchAssetReturnType as bw, createPublicClient as c, createWalletClient as d, FormattedTransactionReceipt as e, FormattedTransactionRequest$1 as f, TransactionRequestFormatter as g, defineBlock as h, defineTransactionReceipt as i, defineTransactionRequest as j, formatBlock as k, formatTransactionRequest as l, CreateContractEventFilterParameters as m, CreateContractEventFilterReturnType as n, EstimateContractGasParameters as o, EstimateContractGasReturnType as p, GetBytecodeReturnType as q, GetStorageAtParameters as r, GetStorageAtReturnType as s, MulticallReturnType as t, OnLogsParameter as u, ReadContractReturnType as v, SimulateContractParameters as w, SimulateContractReturnType as x, WatchContractEventParameters as y, createContractEventFilter as z };