import type { RestoreOptions } from "./errors.js"; import { type Run } from "./asyncContext.js"; import { Checkpoint } from "./state/checkpointStore.js"; /** * Capture a checkpoint of the current execution state. The source * location attached to the checkpoint (`moduleId` / `scopeName` / * `stepPath`) is read from the active `agencyStore` frame's * `callsite` slot, which `Runner.runInScope` seeds for every step * body. Calls made outside a runner step (e.g. from bootstrap scope) * fall back to the empty `""::""::""` location. */ export declare function checkpoint(): Promise; /** `checkpoint()` for a helper that already holds its run, so it can take * a checkpoint after an `await`. */ export declare function checkpointFor(run: Run): Promise; export declare function getCheckpoint(checkpointId: number): Checkpoint; /** `getCheckpoint()` for a helper that already holds its run. */ export declare function getCheckpointFor(run: Run, checkpointId: number): Checkpoint; export declare function restore(checkpointIdOrCheckpoint: number | Checkpoint | Record, options: RestoreOptions): void; /** `restore` for a run the caller already holds. Generated code wraps this * one as an AgencyFunction, whose body is handed the run first. */ export declare function restoreFor(run: Run, checkpointIdOrCheckpoint: number | Checkpoint | Record, options: RestoreOptions): void;