@@ -122,6 +122,11 @@ export function registerCronEditCommand(cron: Command) {
122122 . option ( "--output-max-bytes <n>" , "Maximum captured stdout/stderr bytes for command jobs" )
123123 . option ( "--light-context" , "Enable lightweight bootstrap context for agent jobs" )
124124 . option ( "--no-light-context" , "Disable lightweight bootstrap context for agent jobs" )
125+ . option (
126+ "--fallbacks <list>" ,
127+ "Comma-separated fallback models for agent jobs (e.g. anthropic/claude-haiku-4-5,openai/gpt-5)" ,
128+ )
129+ . option ( "--clear-fallbacks" , "Remove per-job fallback model list" , false )
125130 . option ( "--tools <list>" , "Tool allow-list (e.g. exec,read,write or exec read write)" )
126131 . option ( "--clear-tools" , "Remove tool allow-list (use all tools)" , false )
127132 . option ( "--announce" , "Fallback-deliver final text to a chat" )
@@ -289,6 +294,10 @@ export function registerCronEditCommand(cron: Command) {
289294 throw new Error ( "Use --model or --clear-model, not both" ) ;
290295 }
291296 const thinking = normalizeOptionalString ( opts . thinking ) ;
297+ const fallbacks = parseCronToolsAllow ( opts . fallbacks ) ;
298+ if ( fallbacks && opts . clearFallbacks ) {
299+ throw new Error ( "Use --fallbacks or --clear-fallbacks, not both" ) ;
300+ }
292301 const toolsAllow = parseCronToolsAllow ( opts . tools ) ;
293302 const rawTimeoutSeconds =
294303 opts . timeoutSeconds === undefined ? undefined : String ( opts . timeoutSeconds ) . trim ( ) ;
@@ -380,7 +389,9 @@ export function registerCronEditCommand(cron: Command) {
380389 typeof opts . lightContext === "boolean" ||
381390 typeof opts . tools === "string" ||
382391 Array . isArray ( opts . tools ) ||
383- opts . clearTools ;
392+ opts . clearTools ||
393+ Boolean ( fallbacks ) ||
394+ Boolean ( opts . clearFallbacks ) ;
384395 const hasCommandPayloadField =
385396 hasCommandSpecificPayloadField ||
386397 ( hasTimeoutSeconds &&
@@ -418,6 +429,11 @@ export function registerCronEditCommand(cron: Command) {
418429 } else if ( toolsAllow ) {
419430 payload . toolsAllow = toolsAllow ;
420431 }
432+ if ( opts . clearFallbacks ) {
433+ payload . fallbacks = null ;
434+ } else if ( fallbacks ) {
435+ payload . fallbacks = fallbacks ;
436+ }
421437 patch . payload = payload ;
422438 } else if ( hasCommandPatch ) {
423439 const payload : Record < string , unknown > = { kind : "command" } ;
0 commit comments