UNPKG

openclaw

Version:

Multi-channel AI gateway with extensible messaging integrations

591 lines (590 loc) • 22.4 kB
import { t as hasNonEmptyString } from "./string-coerce-CCIiB4H7.mjs"; import { V as timestampMsToIsoString } from "./number-coercion-D6u-4YD8.mjs"; import { l as isRecord } from "./record-coerce-CVPuDqcc.mjs"; import { n as safeParseJsonRecord } from "./json-coercion-CaJLaav-.mjs"; import "./utils-C8YECn2Q.mjs"; import { t as isStringOption } from "./string-readers-BtMVaphq.mjs"; import { o as expandPolicyWithPluginGroups, r as buildPluginToolGroups } from "./tool-policy-BR4v75RA.mjs"; import { c as normalizeToolPolicyName, i as expandToolGroups, s as normalizeToolList } from "./tool-policy-shared-BHvBopvF.mjs"; import { r as createToolPolicyMatcher } from "./tool-policy-match-DzwVnbV4.mjs"; import { b as readCronScheduledToolProjection } from "./agent-tool-metadata-nrQgRaqv.mjs"; import { c as cronUpdateRequiresStreamExecAuthority, i as cronCreateRequiresStreamExecAuthority, s as cronUpdateNeedsCurrentJobForStreamAuthority } from "./stream-exec-authority-CRx6XpZo.mjs"; //#region src/agents/tools/cron-tool-canonicalize.ts const CRON_SCHEDULE_KINDS = [ "at", "every", "cron", "on-exit", "stream", "event" ]; const CRON_PAYLOAD_KINDS = [ "systemEvent", "agentTurn", "script", "command" ]; const CRON_FLAT_PAYLOAD_KEYS = [ "message", "text", "script", "model", "fallbacks", "toolsAllow", "thinking", "timeoutSeconds", "toolBudget", "lightContext", "includeReasoning", "skipIfScratchEmpty", "allowUnsafeExternalContent" ]; const CRON_FLAT_SCHEDULE_KEYS = [ "kind", "at", "atMs", "every", "everyMs", "anchorMs", "cron", "expr", "tz", "stagger", "staggerMs", "exact", "command", "cwd", "mode", "match", "batchMs", "maxBatchBytes", "source", "options" ]; const CRON_RECOVERABLE_OBJECT_KEYS = /* @__PURE__ */ new Set([ "name", "declarationKey", "displayName", "owner", "schedule", "pacing", "activeHours", "idleOnly", "trigger", "sessionTarget", "wakeMode", "payload", "delivery", "enabled", "description", "deleteAfterRun", "agentId", "sessionKey", "failureAlert", "namePayload", "scheduleKind", "sessionTargetName", ...CRON_FLAT_PAYLOAD_KEYS, ...CRON_FLAT_SCHEDULE_KEYS ]); const CRON_NESTABLE_OBJECT_KEYS = /* @__PURE__ */ new Set([ "activeHours", "delivery", "failureAlert", "owner", "pacing", "activeHours", "idleOnly", "payload", "schedule", "trigger" ]); /** Path segments that would reach Object.prototype when assigned while nesting. */ const CRON_UNSAFE_KEY_SEGMENTS = /* @__PURE__ */ new Set([ "__proto__", "constructor", "prototype" ]); function isCronScheduleKind(e) { return isStringOption(e, CRON_SCHEDULE_KINDS); } function isCronPayloadKind(e) { return isStringOption(e, CRON_PAYLOAD_KINDS); } function isStringArrayOrNull(e) { return e === null || Array.isArray(e) && e.every((e) => typeof e === "string"); } function moveDefinedField(e, t, n, r = n) { if (e[n] === void 0) return false; t[r] = e[n]; delete e[n]; return true; } function repairConcatenatedCronToolKeys(e) { if (!isRecord(e.payload) && isRecord(e.namePayload)) e.payload = { ...e.namePayload }; const t = e.scheduleKind; if (!isRecord(e.schedule)) { if (isRecord(t)) e.schedule = { ...t }; else if (isCronScheduleKind(t)) e.schedule = { kind: t }; } else if (isCronScheduleKind(t) && !isCronScheduleKind(e.schedule.kind)) e.schedule = { ...e.schedule, kind: t }; if (!hasNonEmptyString(e.name) && hasNonEmptyString(e.sessionTargetName)) e.name = e.sessionTargetName; delete e.namePayload; delete e.scheduleKind; delete e.sessionTargetName; } function setScheduleAtMs(e, t) { const n = typeof t === "number" ? t : Number(t); e.at = Number.isFinite(n) ? timestampMsToIsoString(Math.floor(n)) ?? t : t; if (!isCronScheduleKind(e.kind)) e.kind = "at"; } function canonicalizeCronToolSchedule(e) { const t = isRecord(e.schedule) ? { ...e.schedule } : {}; if ((t.command !== void 0 || e.command !== void 0) && !isCronScheduleKind(t.kind) && !isCronScheduleKind(e.kind)) throw new Error("A command schedule needs an explicit schedule.kind. Read the full automations schema and WATCH OUTPUT example before retrying. For a stream, use kind:\"stream\" and command as an argv array."); if (t.atMs !== void 0) { setScheduleAtMs(t, t.atMs); delete t.atMs; } for (const [e, n] of [ ["every", "everyMs"], ["cron", "expr"], ["stagger", "staggerMs"] ]) if (t[n] === void 0) moveDefinedField(t, t, e, n); if (t.exact === true && t.staggerMs === void 0) t.staggerMs = 0; delete t.exact; if (isCronScheduleKind(e.kind) && !isCronScheduleKind(t.kind)) { t.kind = e.kind; delete e.kind; } if (moveDefinedField(e, t, "at") && !isCronScheduleKind(t.kind)) t.kind = "at"; if (e.atMs !== void 0) { setScheduleAtMs(t, e.atMs); delete e.atMs; } for (const [n, r, i] of [[ "every", "everyMs", ["everyMs", "every"] ], [ "cron", "expr", ["cron", "expr"] ]]) if (i.some((n) => moveDefinedField(e, t, n, r)) && !isCronScheduleKind(t.kind)) t.kind = n; moveDefinedField(e, t, "command"); for (const n of [ "anchorMs", "tz", "staggerMs", "cwd", "mode", "match", "batchMs", "maxBatchBytes", "source", "options" ]) moveDefinedField(e, t, n); moveDefinedField(e, t, "stagger", "staggerMs"); if (e.exact === true && t.staggerMs === void 0) t.staggerMs = 0; delete e.exact; if (!isCronScheduleKind(t.kind)) { if (t.at !== void 0) t.kind = "at"; else if (t.everyMs !== void 0) t.kind = "every"; else if (t.expr !== void 0) t.kind = "cron"; } if (isRecord(e.schedule) || Object.keys(t).length > 0) e.schedule = t; } function canonicalizeCronToolPayload(e) { const t = isRecord(e.payload) ? { ...e.payload } : {}; for (const n of CRON_FLAT_PAYLOAD_KEYS) moveDefinedField(e, t, n); if (isCronPayloadKind(e.kind) && !isCronPayloadKind(t.kind)) { t.kind = e.kind; delete e.kind; } if (!isCronPayloadKind(t.kind)) { if (hasNonEmptyString(t.script)) t.kind = "script"; else if (hasNonEmptyString(t.message) || hasNonEmptyString(t.model) || t.model === null || hasNonEmptyString(t.thinking) || typeof t.timeoutSeconds === "number" && hasNonEmptyString(t.text) || typeof t.lightContext === "boolean" || typeof t.includeReasoning === "boolean" || typeof t.skipIfScratchEmpty === "boolean" || typeof t.allowUnsafeExternalContent === "boolean" || t.fallbacks !== void 0 && isStringArrayOrNull(t.fallbacks)) t.kind = "agentTurn"; else if (hasNonEmptyString(t.text)) t.kind = "systemEvent"; } if (isRecord(e.payload) || Object.keys(t).length > 0) e.payload = t; } function repairPaddedCronKeys(e) { for (const t of Object.keys(e)) { const n = t.trim(); if (n !== t && CRON_RECOVERABLE_OBJECT_KEYS.has(n) && !(n in e)) { e[n] = e[t]; delete e[t]; } } } function stripCronKeyQuotes(e) { if (e.length >= 2) { const t = e[0]; if ((t === "\"" || t === "'") && e.endsWith(t)) return e.slice(1, -1); } return e; } function nestDottedCronKey(e, t, n, r) { const i = stripCronKeyQuotes(t.trim()).split(".").map((e) => e.trim()); if (i[0] === "job") i.shift(); const [a, ...o] = i; if (o.length === 0 || !a || !CRON_NESTABLE_OBJECT_KEYS.has(a)) return "ignored"; if (i.some((e) => !e || CRON_UNSAFE_KEY_SEGMENTS.has(e))) return "ignored"; let s = e; for (const [e, t] of i.entries()) { const o = e === i.length - 1; if (t in s) { if (o) return "conflict"; const e = s[t]; if (!isRecord(e)) return "conflict"; if (r.has(a)) return "recovered"; s = e; continue; } if (o) { s[t] = n; return "recovered"; } const c = {}; s[t] = c; s = c; } return "recovered"; } /** Converts model-friendly cron tool shorthands into the nested gateway job/patch shape. */ function canonicalizeCronToolObject(e) { const t = { ...isRecord(e.data) ? e.data : isRecord(e.job) ? e.job : e }; repairPaddedCronKeys(t); repairConcatenatedCronToolKeys(t); canonicalizeCronToolSchedule(t); canonicalizeCronToolPayload(t); return t; } const CRON_CREATE_NULLABLE_TOP_LEVEL_KEYS = /* @__PURE__ */ new Set(["agentId", "sessionKey"]); function deleteNullFields(e, t) { for (const [n, r] of Object.entries(e)) if (r === null && !t?.has(n)) delete e[n]; else if (isRecord(r)) deleteNullFields(r); } /** * Drops null-valued fields from a create job in place. The model-facing job * schema is shared with update, where null means "clear this field"; on create * there is nothing to clear, and the strict gateway cron.add contract rejects * the nulls its update patch accepts. */ function stripCronCreateNullClears(e) { deleteNullFields(e, CRON_CREATE_NULLABLE_TOP_LEVEL_KEYS); return e; } /** Detects recovered update patches that contain no meaningful cron fields after normalization. */ function isEmptyRecoveredCronPatch(e) { if (!isRecord(e)) return true; const t = Object.keys(e); return t.length === 0 || t.length === 1 && t[0] === "payload" && isRecord(e.payload) && Object.keys(e.payload).length === 0; } /** Recovers cron job or patch fields that a model flattened beside the action arguments. */ function recoverCronObjectFromFlatParams(e) { const t = {}; for (const n of Object.keys(e)) if (CRON_RECOVERABLE_OBJECT_KEYS.has(n) && e[n] !== void 0) t[n] = e[n]; const n = new Set(Object.keys(t)); for (const r of Object.keys(e)) { if (CRON_RECOVERABLE_OBJECT_KEYS.has(r) || e[r] === void 0) continue; if (nestDottedCronKey(t, r, e[r], n) === "conflict") t[r] = e[r]; } return { found: Object.keys(t).length > 0, value: canonicalizeCronToolObject(t) }; } /** Checks whether a recovered flat object has enough schedule/payload signal to create a job. */ function hasCronCreateSignal(e) { return e.schedule !== void 0 || e.at !== void 0 || e.atMs !== void 0 || e.everyMs !== void 0 || e.cron !== void 0 || e.expr !== void 0 || e.payload !== void 0 || e.message !== void 0 || e.text !== void 0; } function prepareCronToolArguments(e) { if (!isRecord(e) || e.action !== "add" && e.action !== "update" || e.job === void 0 || isRecord(e.job)) return e; const t = typeof e.job === "string" ? safeParseJsonRecord(e.job) : void 0; if (t) return { ...e, job: t }; const n = { ...e }; readCronToolJob(n, e.action); n.job = void 0; return n; } function readCronToolJob(e, t) { let n = false; if (!isRecord(e.job) || Object.keys(e.job).length === 0) { const r = recoverCronObjectFromFlatParams(e); if (r.found && (t === "update" || hasCronCreateSignal(r.value))) { e.job = r.value; n = true; } } if (!isRecord(e.job)) throw new Error("job required: provide an object or usable flat job fields"); return { job: canonicalizeCronToolObject(e.job), recovered: n }; } //#endregion //#region src/agents/tools/cron-tool-creator-cap.ts /** * Closed core-owned vocabulary a CLI backend may project its native tools into. * Anything else is a backend contract bug and fails closed at capture time so a * raw harness tool name can never become a persisted cron capability. */ const NATIVE_CRON_CREATOR_CAPABILITIES = /* @__PURE__ */ new Set([ "read", "write", "edit", "apply_patch", "exec", "process", "web_search", "web_fetch", "ask_user" ]); /** Fails closed on any backend-projected name outside the exact canonical vocabulary. */ function assertNativeCronCreatorCapabilities(e) { for (const t of e) if (!NATIVE_CRON_CREATOR_CAPABILITIES.has(t)) throw new Error(`cron creator authority rejected non-canonical native capability ${JSON.stringify(t)}`); } const CRON_CREATOR_AUTHORITY_RECOVERY_MESSAGE = "Retry from a fresh authenticated direct-local operator turn, or create/edit via the CLI or Gateway with an explicit finite toolsAllow list containing only currently visible tools; no automation changes were saved."; const INCOMPLETE_CRON_CREATOR_AUTHORITY_MESSAGE = `Configured MCP authority is unavailable because this turn did not capture the complete model-callable tool surface. ${CRON_CREATOR_AUTHORITY_RECOVERY_MESSAGE}`; /** No capture marker means this runtime has no deferred configured-MCP surface. */ function isCronCreatorToolCaptureComplete(e) { return e === void 0 || e.value?.source === "final-executable-surface"; } function assertInheritedCronToolCaptureReady(e, t) { if ((isRecord(e) && isRecord(e.payload) ? e.payload : void 0)?.toolsAllowIsDefault !== true || isCronCreatorToolCaptureComplete(t)) return; throw new Error(INCOMPLETE_CRON_CREATOR_AUTHORITY_MESSAGE); } function replaceWithEffectiveCronCreatorToolAllowlist(e, t, n, r = {}) { e.length = 0; const i = /* @__PURE__ */ new Map(); for (const e of t) { const t = readCronScheduledToolProjection(e); const r = normalizeToolPolicyName(t ? t.targetTool : e.name); if (!r) continue; const a = t ? normalizeToolPolicyName(e.name) : void 0; const o = i.get(r); if (o !== void 0) { if (a && !o.aliasName) o.aliasName = a; if (o.execTarget && !t?.execTarget) delete o.execTarget; else if (o.execTarget?.ask === "always" && t?.execTarget?.ask !== "always") delete o.execTarget.ask; continue; } const s = n?.(e); const c = typeof s?.pluginId === "string" ? normalizeToolPolicyName(s.pluginId) : void 0; i.set(r, { name: r, ...c ? { pluginId: c } : {}, ...a && a !== r ? { aliasName: a } : {}, ...r === "exec" ? { execOrigin: "openclaw" } : {}, ...t?.execTarget ? { execTarget: { ...t.execTarget } } : {} }); } assertNativeCronCreatorCapabilities(r.canonicalToolNames ?? []); for (const e of r.canonicalToolNames ?? []) { if (i.has(e)) continue; i.set(e, e === "exec" ? { name: e, execOrigin: "native", ...r.nativeExecTarget ? { execTarget: { ...r.nativeExecTarget } } : {} } : { name: e }); } e.push(...i.values()); } /** Records the creator cap only after every runtime policy and schema quarantine has run. */ function captureFinalEffectiveCronCreatorToolAllowlist(e, t, n, r, i = {}) { replaceWithEffectiveCronCreatorToolAllowlist(e, n, r, i); t.value = { version: 1, source: "final-executable-surface" }; } function normalizeCronCreatorToolsAllow(e) { const t = []; const n = /* @__PURE__ */ new Set(); for (const r of e) { const e = typeof r === "string" ? { name: r } : r; const i = normalizeToolPolicyName(e.name); if (!i || n.has(i)) continue; n.add(i); const a = typeof e.pluginId === "string" ? normalizeToolPolicyName(e.pluginId) : void 0; const o = typeof e.aliasName === "string" ? normalizeToolPolicyName(e.aliasName) : void 0; const s = e.execOrigin === "openclaw" || e.execOrigin === "native" ? e.execOrigin : void 0; const c = e.execTarget?.host === "gateway" ? { host: "gateway", ...e.execTarget.ask === "always" ? { ask: "always" } : {} } : void 0; t.push({ name: i, ...a ? { pluginId: a } : {}, ...o && o !== i ? { aliasName: o } : {}, ...s ? { execOrigin: s } : {}, ...c ? { execTarget: c } : {} }); } return t; } /** Restrict-only exec target present only when the creator's exec grant is host-pinned. */ function resolveCronCreatorExecToolTarget(e) { const t = normalizeCronCreatorToolsAllow(e ?? []).find((e) => e.name === "exec"); return t?.execTarget ? { ...t.execTarget } : void 0; } /** Requires exec authority whose captured runtime can actually target the Gateway. */ function hasCronCreatorGatewayExecTool(e) { return normalizeCronCreatorToolsAllow(e ?? []).some((e) => e.name === "exec" && (e.execOrigin === "openclaw" || e.execOrigin === "native" && e.execTarget?.host === "gateway")); } /** A native or Gateway-pinned shell cannot grant execution inside an OpenClaw sandbox. */ function hasCronCreatorSandboxExecTool(e) { return normalizeCronCreatorToolsAllow(e ?? []).some((e) => e.name === "exec" && e.execOrigin === "openclaw" && !e.execTarget); } function hasCronTriggerScript(e) { return isRecord(e) && typeof e.script === "string" && e.script.trim().length > 0; } function classifyExplicitToolsAllow(e) { if (!e || !Object.hasOwn(e, "toolsAllow")) return "absent"; if (!Array.isArray(e.toolsAllow)) return "resolved"; const t = e.toolsAllow.filter((e) => typeof e === "string"); if (t.length === 0) return "empty"; return t.some((e) => { const t = normalizeToolPolicyName(e); return t === "*" || t.startsWith("group:"); }) ? "resolved" : "finite"; } function explicitFiniteToolsNeedResolution(e, t) { if (classifyExplicitToolsAllow(e) !== "finite") return false; const n = e?.toolsAllow; if (!Array.isArray(n)) return false; const r = new Set(normalizeCronCreatorToolsAllow(t ?? []).flatMap((e) => e.aliasName ? [e.name, e.aliasName] : [e.name])); return expandToolGroups(n.filter((e) => typeof e === "string")).some((e) => !r.has(e)); } /** Whether an add needs the creator's complete authority rather than an explicit empty cap. */ function cronCreateRequiresCreatorAuthority(e, t) { if (!isRecord(e)) return false; if (cronCreateRequiresStreamExecAuthority(e)) return true; const n = isRecord(e.payload) ? e.payload : void 0; const r = classifyExplicitToolsAllow(n); if (r === "empty") return false; if (r === "finite") return explicitFiniteToolsNeedResolution(n, t); return hasCronTriggerScript(e.trigger) || n?.kind === "agentTurn" || n?.kind === "script" || r === "resolved"; } function capCronJobToolsAllow(e) { const t = Object.hasOwn(e.payload, "toolsAllow"); if (e.payload.kind !== "agentTurn" && e.payload.kind !== "script" && !hasCronTriggerScript(e.trigger) && !t) return; const n = normalizeCronCreatorToolsAllow(e.creatorToolAllowlist); const r = t ? e.payload.toolsAllow : e.defaultToolsAllow; const i = Array.isArray(r) ? normalizeToolList(r.filter((e) => typeof e === "string")) : ["*"]; if (i.includes("*")) { if (e.payload.kind === "agentTurn" && !hasCronTriggerScript(e.trigger) && !e.creatorHoldsRuntimeAuthority) { e.payload.toolsAllow = ["*"]; delete e.payload.toolsAllowIsDefault; } else { e.payload.toolsAllow = n.map((e) => e.name); e.payload.toolsAllowIsDefault = true; } return; } const a = buildPluginToolGroups({ tools: n, toolMeta: (e) => e.pluginId ? { pluginId: e.pluginId } : void 0 }); const o = new Set(i.flatMap((e) => { const t = createToolPolicyMatcher(expandPolicyWithPluginGroups({ allow: [e] }, a)); const r = n.filter((e) => t(e.name) || e.aliasName !== void 0 && t(e.aliasName)); if (r.length === 0) throw new Error(`Requested automation tool ${JSON.stringify(e)} cannot be carried from this creator turn. No automation changes were saved. Use a supported tool name and creator runtime, or explicitly remove it from toolsAllow.`); return r; })); e.payload.toolsAllow = n.filter((e) => o.has(e)).map((e) => e.name); delete e.payload.toolsAllowIsDefault; } function capCronJobToolsAllowOnCreate(e, t, n) { if (!isRecord(e) || !isRecord(e.payload) || !t) return; capCronJobToolsAllow({ payload: e.payload, trigger: e.trigger, creatorToolAllowlist: t, creatorHoldsRuntimeAuthority: n }); } function readCronPayloadKind(e) { return isRecord(e) && typeof e.kind === "string" ? e.kind : void 0; } /** Purely derives the agent-tool patch; current job state is requested only when required. */ function planCronJobUpdatePatch(e) { const t = { ...e.patch }; const n = isRecord(t.payload) ? { ...t.payload } : void 0; if (n) t.payload = n; if (cronUpdateNeedsCurrentJobForStreamAuthority(t) && !e.currentJob) return { kind: "needs-current-job" }; if (e.creatorAuthorityComplete === false && e.currentJob && cronUpdateRequiresStreamExecAuthority(t, e.currentJob)) return { kind: "needs-creator-authority" }; const r = readCronPayloadKind(n); const i = classifyExplicitToolsAllow(n); if (n === void 0 && !Object.hasOwn(t, "trigger")) return { kind: "ready", patch: t }; if (r !== void 0 && i === "absent" && e.creatorAuthorityComplete !== false && !e.creatorToolAllowlist && !Object.hasOwn(t, "trigger")) return { kind: "ready", patch: t }; if (e.creatorAuthorityComplete === false && explicitFiniteToolsNeedResolution(n, e.creatorToolAllowlist)) return { kind: "needs-creator-authority" }; if (e.creatorToolAllowlist && (i === "empty" || i === "finite") && r !== void 0) { capCronJobToolsAllow({ payload: n, trigger: t.trigger, creatorToolAllowlist: e.creatorToolAllowlist }); return { kind: "ready", patch: t }; } if (!e.currentJob) return { kind: "needs-current-job" }; const a = e.currentJob.payload; const o = isRecord(a) ? a : void 0; const s = readCronPayloadKind(a); const c = r ?? s; if (n && c !== void 0) { n.kind = c; t.payload = n; } const l = Object.hasOwn(t, "trigger") ? t.trigger : e.currentJob.trigger; const u = r !== void 0 && r !== s && (c === "agentTurn" || c === "script"); const d = Object.hasOwn(t, "trigger") && hasCronTriggerScript(l) && !hasCronTriggerScript(e.currentJob.trigger); const f = i === "absent" && (u || d) && (o?.toolsAllowIsDefault === true || !Array.isArray(o?.toolsAllow) || o.toolsAllow.includes("*") && (c === "script" || d)); const p = i === "resolved" || f || explicitFiniteToolsNeedResolution(n, e.creatorToolAllowlist); if (p && e.creatorAuthorityComplete === false) return { kind: "needs-creator-authority" }; if (!p && (i === "empty" || i === "finite") && e.creatorToolAllowlist) { capCronJobToolsAllow({ payload: n, trigger: l, creatorToolAllowlist: e.creatorToolAllowlist }); return { kind: "ready", patch: t }; } if (!p || !e.creatorToolAllowlist) return { kind: "ready", patch: t }; const m = n ?? {}; if (c !== void 0) m.kind = c; t.payload = m; capCronJobToolsAllow({ payload: m, trigger: l, creatorToolAllowlist: e.creatorToolAllowlist, defaultToolsAllow: o && o.toolsAllowIsDefault !== true ? o.toolsAllow : void 0, creatorHoldsRuntimeAuthority: e.creatorHoldsRuntimeAuthority }); return { kind: "ready", patch: t }; } //#endregion export { stripCronCreateNullClears as _, capCronJobToolsAllowOnCreate as a, hasCronCreatorGatewayExecTool as c, planCronJobUpdatePatch as d, replaceWithEffectiveCronCreatorToolAllowlist as f, readCronToolJob as g, prepareCronToolArguments as h, assertNativeCronCreatorCapabilities as i, hasCronCreatorSandboxExecTool as l, isEmptyRecoveredCronPatch as m, INCOMPLETE_CRON_CREATOR_AUTHORITY_MESSAGE as n, captureFinalEffectiveCronCreatorToolAllowlist as o, resolveCronCreatorExecToolTarget as p, assertInheritedCronToolCaptureReady as r, cronCreateRequiresCreatorAuthority as s, CRON_CREATOR_AUTHORITY_RECOVERY_MESSAGE as t, isCronCreatorToolCaptureComplete as u };