Skip to content

[Bug] Cron agentTurn payload.model parameter is ignored - jobs run on wrong model #6828

@ryanszu9904-collab

Description

@ryanszu9904-collab

Description

When creating cron jobs with payload.kind: "agentTurn" and specifying a model parameter in the payload, the model parameter is ignored and the job runs on the session's default model (or Opus) instead.

Steps to Reproduce

  1. Create a cron job with agentTurn payload:
{
  "name": "test-gemini",
  "schedule": { "kind": "cron", "expr": "0 * * * *" },
  "payload": {
    "kind": "agentTurn",
    "message": "Test message",
    "model": "google/gemini-2.5-flash"  // Should use Gemini
  },
  "sessionTarget": "isolated"
}
  1. Observe that the job runs on Opus instead of Gemini

Expected Behavior

The cron job should use the model specified in payload.model (e.g., google/gemini-2.5-flash).

Actual Behavior

The model parameter is ignored and the job runs on the more expensive default model (Opus), causing unnecessary token costs.

Environment

  • OpenClaw version: Latest (Feb 2026)
  • Platform: macOS (arm64)

Additional Context

This makes cost-conscious scheduling impossible since cheap/free models (like Gemini) cannot be targeted for routine tasks. The workaround is to disable automated jobs and run everything manually, which defeats the purpose of cron scheduling.

The same issue may affect the thinking parameter in agentTurn payloads.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions