import type { MultichainCore } from '@metamask/connect-multichain'; import { EventEmitter } from '@metamask/connect-multichain'; import type { Address, EIP1193ProviderEvents, Hex, JsonRpcCallback, JsonRpcRequest, JsonRpcResponse, ProviderRequest, ProviderRequestInterceptor } from './types'; /** * EIP-1193 Provider wrapper around the Multichain SDK. */ export declare class EIP1193Provider extends EventEmitter { #private; constructor(core: MultichainCore, interceptor: ProviderRequestInterceptor); /** * Performs a EIP-1193 request. * * @param request - The request object containing the method and params * @returns The result of the request */ request(request: ProviderRequest): Promise; get selectedAccount(): Address | undefined; set accounts(accounts: Address[]); get accounts(): Address[]; get selectedChainId(): Hex | undefined; set selectedChainId(chainId: Hex | undefined); /** * Alias for selectedChainId for legacy compatibility. * Many dApps expect a `chainId` property on the provider. */ get chainId(): Hex | undefined; /** * Legacy method for sending JSON-RPC requests. * * @deprecated Use `request` instead. This method is provided for backwards compatibility. * @param request - The JSON-RPC request object * @param callback - Optional callback function. If provided, the method returns void. * @returns A promise resolving to the JSON-RPC response, or void if a callback is provided. */ sendAsync(request: JsonRpcRequest, callback?: JsonRpcCallback): Promise | void>; /** * Legacy method for sending JSON-RPC requests synchronously (callback-based). * * @deprecated Use `request` instead. This method is provided for backwards compatibility. * @param request - The JSON-RPC request object * @param callback - The callback function to receive the response */ send(request: JsonRpcRequest, callback: JsonRpcCallback): void; } //# sourceMappingURL=provider.d.ts.map