// lib/ethereum.ts
import { HttpProvider } from '@tevm/voltaire/provider';
export const provider = new HttpProvider({
url: import.meta.env.VITE_RPC_URL ?? 'https://eth.llamarpc.com',
timeout: 15_000,
});
export const ethKeys = {
blockNumber: () => ['eth', 'blockNumber'] as const,
balance: (address: string) => ['eth', 'balance', address.toLowerCase()] as const,
nonce: (address: string) => ['eth', 'nonce', address.toLowerCase()] as const,
block: (tag: string) => ['eth', 'block', tag] as const,
receipt: (hash: string) => ['eth', 'receipt', hash.toLowerCase()] as const,
};