export declare function safeRunPathSlug(value: string | undefined, fallback: string): string; export declare function workflowRunSubjectKey(kind: string | undefined, rawSubjectRef: string | undefined): string; export declare function workflowRunProjectSlug(projectKey: string | undefined): string; export interface WorkflowRunManifestArgs { loopsDataDir: string; workflowRunId: string; workflowId: string; workflowName: string; invocationId?: string; workItemId?: string; projectKey?: string; subjectKind?: string; rawSubjectRef?: string; payload: Record; } export interface StagedWorkflowRunManifest { /** Final manifest.json location, valid only after {@link commitWorkflowRunManifest}. */ manifestPath: string; /** Temp file holding the staged manifest content. */ tmpPath: string; } /** * Write the manifest to `manifest.json.tmp` so callers can stage the * filesystem side effect before opening a database transaction and promote it * with {@link commitWorkflowRunManifest} only after COMMIT succeeds. */ export declare function stageWorkflowRunManifest(args: WorkflowRunManifestArgs): StagedWorkflowRunManifest; export declare function commitWorkflowRunManifest(staged: StagedWorkflowRunManifest): string; export declare function discardWorkflowRunManifest(staged: StagedWorkflowRunManifest): void; export declare function writeWorkflowRunManifest(args: WorkflowRunManifestArgs): string;