{"record":{"id":"19a995d803f4f101","repo":"stablyai/orca","slug":"only-hermes-cron-creation-and-editing-are-supporte","errorCode":null,"errorMessage":"Only Hermes cron creation and editing are supported.","messagePattern":"Only Hermes cron creation and editing are supported\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/main/automations/external-manager.ts","lineNumber":413,"sourceCode":"    case 'pause':\n      return 'disable'\n    case 'resume':\n      return 'enable'\n    case 'run':\n      return 'run'\n    case 'delete':\n      return 'rm'\n  }\n}\n\nfunction normalizeHermesCronMutationInput(input: ExternalAutomationCreateInput): {\n  name: string\n  prompt: string\n  schedule: string\n  workdir: string | null\n} {\n  if (input.provider !== 'hermes') {\n    throw new Error('Only Hermes cron creation and editing are supported.')\n  }\n  const name = input.name.trim()\n  const prompt = input.prompt.trim()\n  const schedule = input.schedule.trim()\n  const workdir = input.workdir?.trim() || null\n  if (!prompt) {\n    throw new Error('Hermes cron requires a prompt.')\n  }\n  if (!schedule) {\n    throw new Error('Hermes cron requires a schedule.')\n  }\n  return {\n    name: name || prompt.slice(0, 50).trim() || 'Hermes cron',\n    prompt,\n    schedule,\n    workdir\n  }\n}","sourceCodeStart":395,"sourceCodeEnd":431,"githubUrl":"https://github.com/stablyai/orca/blob/1136503c6a231a16dce8f921f6fadb63d181e8db/src/main/automations/external-manager.ts#L395-L431","documentation":"Thrown by normalizeHermesCronMutationInput() when input.provider is not 'hermes'. The create/edit path currently implements only Hermes cron mutations; any other provider value is rejected before argument building. This is a capability guard, not a runtime/network condition.","triggerScenarios":"Calling createExternalAutomation or updateExternalAutomation with provider set to anything other than 'hermes' (e.g. 'openclaw', an empty string, or a typo).","commonSituations":"A UI dropdown offers multiple providers but only Hermes is wired; a caller forwards a stale/default provider value; OpenClaw support is half-implemented and the create path was reached before its branch existed.","solutions":["Only invoke create/update with provider: 'hermes'; gate or hide other providers in the UI until they are supported.","If you need another provider, implement and register its normalization/args branch first, then widen this guard.","Validate input.provider against the supported set ('hermes') before calling."],"exampleFix":"// before\ncreateExternalAutomation({ provider: 'openclaw', ... }) // throws\n\n// after\nif (input.provider !== 'hermes') {\n  throw new UserError('Only Hermes cron automation is supported.')\n}\ncreateExternalAutomation({ provider: 'hermes', ... })","handlingStrategy":"validation","validationCode":"const SUPPORTED_AUTOMATION_PROVIDERS = ['hermes'] as const\n\nfunction isSupportedAutomationProvider(p: string): boolean {\n  return (SUPPORTED_AUTOMATION_PROVIDERS as readonly string[]).includes(p)\n}\n\nif (!isSupportedAutomationProvider(input.provider)) {\n  throw new UserError('Only Hermes cron automation is currently supported.')\n}\ncreateExternalAutomation(input)","typeGuard":"type SupportedAutomationProvider = 'hermes'\nfunction isSupportedAutomationProvider(p: unknown): p is SupportedAutomationProvider {\n  return p === 'hermes'\n}","tryCatchPattern":"try {\n  await createExternalAutomation(input)\n} catch (e) {\n  if ((e as Error).message === 'Only Hermes cron creation and editing are supported.') {\n    throw new UserError('Only Hermes cron automation is supported right now.')\n  }\n  throw e\n}","preventionTips":["Restrict the provider picker in the UI to supported values; hide unimplemented providers.","Centralize the supported-provider list in one constant shared by UI and manager.","Widen this guard only after the new provider's normalize/args branch is implemented and tested."],"tags":["automations","hermes","provider","capability","precondition"],"backgroundTag":null,"analyzedSha":"1136503c6a231a16dce8f921f6fadb63d181e8db","analyzedAt":"2026-08-12T23:15:58.167Z","schemaVersion":2},"datasetVersion":"2026-08-12T23:17:12.415Z"}