import { L as LiveConnector, C as ConnectorConfig, a as ConnectorDocument } from './framework-CyHYDcri.js';
import { LiveConnectorsConfig } from './types.js';
import './index-1qIcnbG1.js';

type LiveConnectorSkipReason = "disabled" | "not_due" | "invalid_config" | "state_read_error" | "connector_error";
interface LiveConnectorRunItem {
    id: string;
    displayName: string;
    enabled: boolean;
    ran: boolean;
    skippedReason?: LiveConnectorSkipReason;
    docsImported: number;
    error?: string;
    stateWriteError?: string;
    lastSyncAt: string | null;
    nextDueAt: string | null;
}
interface LiveConnectorsRunSummary {
    ranAt: string;
    force: boolean;
    totalDocsImported: number;
    ranCount: number;
    skippedCount: number;
    errorCount: number;
    results: LiveConnectorRunItem[];
}
interface LiveConnectorDefinition {
    id: string;
    displayName: string;
    enabled: boolean;
    pollIntervalMs: number;
    rawConfig: unknown;
    createConnector: () => LiveConnector;
    validateConfig: (raw: unknown) => ConnectorConfig;
}
type LiveConnectorsNow = Date | (() => Date);
declare function builtInLiveConnectorDefinitions(config: LiveConnectorsConfig): LiveConnectorDefinition[];
declare function hasEnabledLiveConnector(config: LiveConnectorsConfig): boolean;
declare function runLiveConnectorsOnce(options: {
    memoryDir: string;
    connectors: LiveConnectorsConfig;
    ingestDocuments: (docs: ConnectorDocument[]) => Promise<void>;
    force?: boolean;
    now?: LiveConnectorsNow;
    abortSignal?: AbortSignal;
    definitions?: LiveConnectorDefinition[];
}): Promise<LiveConnectorsRunSummary>;

export { type LiveConnectorDefinition, type LiveConnectorRunItem, type LiveConnectorSkipReason, type LiveConnectorsRunSummary, builtInLiveConnectorDefinitions, hasEnabledLiveConnector, runLiveConnectorsOnce };
