import { type RuntimeGitRepositoryInfo, type RuntimeWorkspaceStateResponse, type RuntimeWorkspaceStateSaveRequest } from "../core/api-contract.js";
export interface RuntimeWorkspaceIndexEntry {
    workspaceId: string;
    repoPath: string;
}
export interface RuntimeWorkspaceContext {
    repoPath: string;
    workspaceId: string;
    statePath: string;
    git: RuntimeGitRepositoryInfo;
}
export interface LoadWorkspaceContextOptions {
    autoCreateIfMissing?: boolean;
}
export declare function getRuntimeHomePath(): string;
export declare function getWorkspacesRootPath(): string;
export declare function getWorkspaceDirectoryPath(workspaceId: string): string;
export declare class WorkspaceStateConflictError extends Error {
    readonly currentRevision: number;
    constructor(expectedRevision: number, currentRevision: number);
}
export declare function loadWorkspaceContext(cwd: string, options?: LoadWorkspaceContextOptions): Promise<RuntimeWorkspaceContext>;
export declare function loadWorkspaceContextById(workspaceId: string): Promise<RuntimeWorkspaceContext | null>;
export declare function listWorkspaceIndexEntries(): Promise<RuntimeWorkspaceIndexEntry[]>;
export declare function removeWorkspaceIndexEntry(workspaceId: string): Promise<boolean>;
export declare function removeWorkspaceStateFiles(workspaceId: string): Promise<void>;
export declare function loadWorkspaceState(cwd: string): Promise<RuntimeWorkspaceStateResponse>;
export declare function saveWorkspaceState(cwd: string, payload: RuntimeWorkspaceStateSaveRequest): Promise<RuntimeWorkspaceStateResponse>;
//# sourceMappingURL=workspace-state.d.ts.map