import type { Stream } from "effect"; import { Context, Effect, Layer } from "effect"; import type { Block, Hash } from "viem"; import type { ClientNotFoundError } from "../core/index.js"; import { PublicClientService, TransportError } from "../core/index.js"; import { BlockNotFoundError, BlockTimeoutError } from "./errors.js"; export type BlockServiceShape = { readonly getBlock: (params: { chainId: number; blockNumber?: bigint; blockTag?: "latest" | "pending" | "earliest" | "safe" | "finalized"; includeTransactions?: boolean; }) => Effect.Effect; readonly getBlockByHash: (params: { chainId: number; hash: Hash; includeTransactions?: boolean; }) => Effect.Effect; readonly getBlockNumber: (params: { chainId: number; }) => Effect.Effect; readonly watchBlocks: (params: { chainId: number; pollingInterval?: number; includeTransactions?: boolean; }) => Effect.Effect, ClientNotFoundError>; readonly waitForBlock: (params: { chainId: number; blockNumber: bigint; timeout?: number; }) => Effect.Effect; readonly getBlocks: (params: { chainId: number; fromBlock: bigint; toBlock: bigint; includeTransactions?: boolean; }) => Effect.Effect; readonly getBlockTimestamp: (params: { chainId: number; blockNumber?: bigint; }) => Effect.Effect; }; declare const BlockService_base: Context.TagClass; export declare class BlockService extends BlockService_base { } export declare const BlockServiceLive: Layer.Layer; export {}; //# sourceMappingURL=service.d.ts.map