import { CustomChainConfig, IProvider } from "@web3auth/base"; import { BaseProvider, BaseProviderConfig, BaseProviderState } from "@web3auth/base-provider"; import { Client } from "viem"; import { BundlerClient, PaymasterClient, SmartAccount } from "viem/account-abstraction"; import { ISmartAccount } from "./smartAccounts"; import { BundlerConfig, PaymasterConfig } from "./types"; export interface AccountAbstractionProviderConfig extends BaseProviderConfig { smartAccountInit: ISmartAccount; bundlerConfig: BundlerConfig; paymasterConfig?: PaymasterConfig; } export interface AccountAbstractionProviderState extends BaseProviderState { eoaProvider?: IProvider; } export declare class AccountAbstractionProvider extends BaseProvider { readonly PROVIDER_CHAIN_NAMESPACE: "eip155"; private _smartAccount; private _publicClient; private _bundlerClient; private _paymasterClient; constructor({ config, state }: { config: AccountAbstractionProviderConfig; state?: AccountAbstractionProviderState; }); get smartAccount(): SmartAccount | null; get bundlerClient(): BundlerClient | null; get paymasterClient(): PaymasterClient | null; get publicClient(): Client | null; static getProviderInstance: (params: { eoaProvider: IProvider; smartAccountInit: ISmartAccount; chainConfig: CustomChainConfig; bundlerConfig: BundlerConfig; paymasterConfig?: PaymasterConfig; }) => Promise; enable(): Promise; setupProvider(eoaProvider: IProvider): Promise; updateAccount(_params: { privateKey: string; }): Promise; switchChain(_params: { chainId: string; }): Promise; protected lookupNetwork(): Promise; private setupChainSwitchMiddleware; }