import type { Payload } from '@xyo-network/sdk'; /** Parses and validates raw diviner payloads into typed indexed results. */ export type ParseIndexedResults = (payloads: Payload[]) => Promise; /** Functions used to evaluate freshness and parse indexed diviner results. */ export interface ProcessIndexedResults { /** function to ensure the results meets a required level of freshness */ isFresh?: (payloads?: Payload[] | null) => boolean; /** Validate and parse results from the diviner(s) (i.e. validate and resolve the hashes that are in the query result) */ parseIndexedResults: ParseIndexedResults; } /** Configuration for resolving, polling, and refreshing indexed payload results. */ export interface IndexedResultsConfig { /** diviner that can check the the archivist for the latest results */ diviners: string[]; /** query to search for indexed results */ indexedQueries: Payload[]; /** Functions to process indexedResults */ processIndexedResults: ProcessIndexedResults; /** Budget */ queryBudget?: Payload; /** Function to get a fresh result (i.e. sentinel report or witness observation) */ refresh?: (params: Partial) => Promise; } //# sourceMappingURL=IndexedResultsConfig.d.ts.map