import type { Logger } from "pino";
import { AgentManager } from "../agent/agent-manager.js";
import type { AgentStorage } from "../agent/agent-storage.js";
import type { ProviderSnapshotManager } from "../agent/provider-snapshot-manager.js";
import type { CreateScheduleInput, ScheduleExecutionResult, ScheduleRun, StoredSchedule, UpdateScheduleInput } from "@kong-link/protocol/schedule/types";
type CreateConfigResolver = Pick<ProviderSnapshotManager, "resolveCreateConfig">;
export interface ScheduleServiceOptions {
    paseoHome: string;
    logger: Logger;
    agentManager: AgentManager;
    agentStorage: AgentStorage;
    providerSnapshotManager: CreateConfigResolver;
    now?: () => Date;
    runner?: (schedule: StoredSchedule, runId: string) => Promise<ScheduleExecutionResult>;
}
export declare class ScheduleService {
    private readonly store;
    private readonly logger;
    private readonly agentManager;
    private readonly agentStorage;
    private readonly createConfigResolver;
    private readonly now;
    private readonly runner;
    private readonly runningScheduleIds;
    private tickTimer;
    constructor(options: ScheduleServiceOptions);
    start(): Promise<void>;
    stop(): Promise<void>;
    create(input: CreateScheduleInput): Promise<StoredSchedule>;
    list(): Promise<StoredSchedule[]>;
    inspect(id: string): Promise<StoredSchedule>;
    logs(id: string): Promise<ScheduleRun[]>;
    pause(id: string): Promise<StoredSchedule>;
    resume(id: string): Promise<StoredSchedule>;
    update(input: UpdateScheduleInput): Promise<StoredSchedule>;
    delete(id: string): Promise<void>;
    deleteForAgent(agentId: string): Promise<number>;
    runOnce(id: string): Promise<StoredSchedule>;
    tick(): Promise<void>;
    private recoverInterruptedRuns;
    private runSchedule;
    private finishRun;
    private executeSchedule;
    private resolveProviderCreateConfig;
}
export {};
//# sourceMappingURL=service.d.ts.map