import { Address, Chain, PublicClient, Transport } from 'viem'; export type GetValidatorsParams = { /** Address of the rollup we're getting list of validators from */ rollup: Address; }; export type GetValidatorsReturnType = { /** * If logs contain unknown signature, validators list might: * - contain false positives (validators that were removed, but returned as validator) * - contain false negatives (validators that were added, but not present in the list) */ isAccurate: boolean; /** List of validators for the given rollup */ validators: Address[]; }; /** * * @param {PublicClient} publicClient - The chain Viem Public Client * @param {GetValidatorsParams} GetValidatorsParams {@link GetValidatorsParams} * * @returns Promise<{@link GetValidatorsReturnType}> * * @remarks validators list is not guaranteed to be exhaustive if the `isAccurate` flag is false. * It might contain false positive (validators that were removed, but returned as validator) * or false negative (validators that were added, but not present in the list) * * @example * const { isAccurate, validators } = getValidators(client, { rollup: '0xc47dacfbaa80bd9d8112f4e8069482c2a3221336' }); * * if (isAccurate) { * // Validators were all fetched properly * } else { * // Validators list is not guaranteed to be accurate * } */ export declare function getValidators(publicClient: PublicClient, { rollup }: GetValidatorsParams): Promise;