/** * Curated public API for @hasna/loops. * * Stable exports are safe to build on and follow semver. Experimental exports * may change shape between minor versions; import them knowingly. The * `@hasna/loops/storage` subpath (the raw Store) is internal plumbing kept * only for advanced integrations and may change without notice. */ export { LoopsClient, loops, openAutomationsRuntimeBinding } from "./sdk/index.js"; export type { ListLoopsFilters, ListRunsFilters, LoopsClientOptions } from "./sdk/index.js"; export { createLoopsMcpServer, listToolsForCli, LOOPS_MCP_TOOLS } from "./mcp/index.js"; export type { LoopsMcpToolMetadata } from "./mcp/index.js"; export { AmbiguousNameError, CodedError, LoopArchivedError, LoopNotFoundError, ValidationError } from "./lib/errors.js"; export type { CatchUpPolicy, CreateLoopInput, ExecutorResult, IntervalAnchor, Loop, LoopRun, LoopStatus, OverlapPolicy, RunStatus, TimeoutMs, CronSchedule, DynamicSchedule, IntervalSchedule, OnceSchedule, ScheduleSpec, AccountRef, AgentAllowlistSpec, AgentConfigIsolation, AgentPermissionMode, AgentPromptSource, AgentProvider, AgentRoutingSpec, AgentSandbox, AgentSessionContract, AgentTarget, AgentTargetBase, AgentWorktreeMode, AgentWorktreeSpec, CommandTarget, ExecutableTarget, ExecutableTargetInput, LoopTarget, LoopTargetInput, PromptFileAgentTarget, RuntimePreflightPolicy, WorkflowTarget, AgentSessionContractWorkflowEvent, CreateWorkflowInput, CustomWorkflowEvent, GenericWorkflowEvent, PublicWorkflowEvent, WorkflowEvent, WorkflowEventBase, WorkflowLifecycleEventType, WorkflowRun, WorkflowRunStatus, WorkflowSpec, WorkflowStatus, WorkflowStep, WorkflowStepInput, WorkflowStepRun, WorkflowStepRunStatus, } from "./types.js"; export { runDoctor } from "./lib/doctor.js"; export type { DoctorCheck, DoctorReport, DoctorSeverity } from "./lib/doctor.js"; export { buildHealthReport, buildHealthScan, classifyRunFailure, expectationForLoop, writeHealthScanReports } from "./lib/health.js"; export type { BuildHealthScanOptions, HealthScanFinding, HealthScanFindingKind, HealthScanFindingSeverity, HealthScanSelfHealAction, HealthScanStatus, LoopExpectationResult, LoopsHealthReport, LoopsHealthScan, RunFailureClassification, RunFailureSignal, WriteHealthScanReportsOptions, } from "./lib/health.js"; export { computeNextAfter, initialNextRun, nextCronRun, parseCron, parseDuration } from "./lib/recurrence.js"; export { runLoopNow, tick } from "./lib/scheduler.js"; export type { ManualRunSource, RunLoopNowDeps, RunLoopNowExecuted, RunLoopNowMode, RunLoopNowResult, RunLoopNowScheduled, } from "./lib/scheduler.js"; export { Store } from "./lib/store.js"; export { POSTGRES_MIGRATION_LEDGER_TABLE, POSTGRES_STORAGE_MIGRATIONS, PostgresStorage, SqliteLoopStorage, checksumStorageSql, createPostgresStorage, createSqliteLoopStorage, } from "./lib/storage/index.js"; export type { AppliedStorageMigration, AuditEventRecord, LoopStorageBackend, LoopStorageContract, LoopStorageMethodName, PostgresQueryExecutor, RunnerLeaseRecord, RunnerLeaseStatus, RunnerMachineRecord, RunnerMachineStatus, SchemaMigrationStorage, StorageMigration, StorageMigrationPlanItem, StorageMigrationResult, } from "./lib/storage/index.js"; export { ROUTE_ADMISSION_GATES, displayControlPlaneUrl, loopControlPlaneConfig, resolveRuntimeConfig, runtimeStorage, runtimeStorageBackend, } from "./lib/runtime-config.js"; export type { LoopControlPlaneConfig, LoopRouteAdmissionGate, RuntimeConfig, RuntimeConnection, RuntimeStorage, RuntimeStorageBackend, } from "./lib/runtime-config.js"; export { buildStorageConnectionReport, schedulerStateForConnection, storageConnectionReportLine, } from "./lib/runtime-status.js"; export type { LoopRemoteArtifactStore, LoopRemoteSchedulerBackend, LoopRouteAdmissionStateStore, LoopSchedulerStateStatus, StorageConnectionReport, } from "./lib/runtime-status.js"; export { executeLoop, executeTarget, preflightTarget } from "./lib/executor.js"; export { executeLoopTarget, executeWorkflow, preflightWorkflow } from "./lib/workflow-runner.js"; export { workflowBodyFromJson, workflowExecutionOrder } from "./lib/workflow-spec.js"; export { listOpenMachines, refreshLoopMachine, resolveLoopMachine } from "./lib/machines.js"; export { BOUNDED_AGENT_WORKER_VERIFIER_TEMPLATE_ID, EVENT_WORKER_VERIFIER_TEMPLATE_ID, TODOS_TASK_WORKER_VERIFIER_TEMPLATE_ID, getLoopTemplate, listLoopTemplates, renderBoundedAgentWorkerVerifierWorkflow, renderEventWorkerVerifierWorkflow, renderLoopTemplate, renderTodosTaskWorkerVerifierWorkflow, } from "./lib/templates.js"; export { buildDuplicateOverlapReport, buildNameHygieneReport, buildScriptInventoryReport } from "./lib/hygiene.js"; export { LOOPS_MIGRATION_SCHEMA, applyImportMigrationBundle, buildImportMigrationPlan, buildControlPlaneMigrationPlan, exportLoopsMigrationBundle, migrationHash, publicMigrationBundle, controlPlaneSummary, validateLoopsMigrationBundle, } from "./lib/migration.js"; export { runGoal } from "./lib/goal/runner.js"; export { resolveGoalModel } from "./lib/goal/model-factory.js"; export { isTerminal as isGoalTerminal, readyNodeKeys, rollupSummary } from "./lib/goal/status.js"; export type { CreateWorkflowInvocationInput, Goal, GoalAutoExecute, GoalExecutorResult, GoalPlan, GoalPlanNode, GoalPlanNodeStatus, GoalPlanStatus, GoalRollup, GoalRun, GoalSpec, GoalStatus, LoopMachineConfidence, LoopMachineRef, LoopMachineRoute, LoopTemplateKind, LoopTemplateSource, LoopTemplateSummary, LoopTemplateVariable, LoopTemplateVariableType, OpenAutomationsRuntimeBinding, PersistGuardOptions, UpsertWorkflowWorkItemInput, WorkflowInvocation, WorkflowInvocationIntent, WorkflowInvocationOutputPolicy, WorkflowInvocationRef, WorkflowInvocationScope, WorkflowInvocationSourceKind, WorkflowInvocationSubjectKind, WorkflowWorkItem, WorkflowWorkItemStatus, } from "./types.js"; export type { ApplyLoopsMigrationResult, ExportLoopsMigrationOptions, ImportLoopsMigrationOptions, LoopsMigrationAction, LoopsMigrationBundle, LoopsMigrationPlan, LoopsMigrationPlanRow, LoopsMigrationPlanSummary, LoopsMigrationResource, ControlPlanePlanOptions, } from "./lib/migration.js";