Remote OpenClaw

Remote OpenClaw Blog

Dispatch Scheduling Best Practices for OpenClaw Operators

8 min read ·

Getting Dispatch workflows to run on a schedule is easy. Getting them to run reliably, efficiently, and without burning through your token budget is the hard part. Most operators set up a few cron jobs, watch them work for a day, and then forget about them — until something fails silently and they discover the problem three weeks later.

This guide covers the scheduling best practices that separate hobbyist setups from production-grade OpenClaw deployments. For the foundational Dispatch concepts, start with the Claude Dispatch guide. For the related cron and scheduling features, see the scheduled tasks and cron guide.


Cron Patterns for Dispatch

Dispatch uses standard five-field cron syntax. If you have used crontab on Linux, you already know the format:

# Format: minute hour day-of-month month day-of-week
# Examples:

# Every day at 8:00 AM
0 8 * * *

# Every weekday at 8:00 AM
0 8 * * 1-5

# Every 15 minutes
*/15 * * * *

# Every Monday at 9:00 AM
0 9 * * 1

# First day of every month at midnight
0 0 1 * *

Dispatch also supports shorthand expressions:

ShorthandEquivalent cronDescription
@hourly0 * * * *Start of every hour
@daily0 0 * * *Midnight every day
@weekly0 0 * * 0Midnight every Sunday
@monthly0 0 1 * *Midnight on the 1st of each month

Timezone handling

By default, Dispatch interprets cron times in the timezone configured on your OpenClaw instance. You can override this per workflow:

{
  "name": "morning-briefing",
  "trigger": {
    "cron": "0 8 * * 1-5",
    "timezone": "America/New_York"
  }
}

This is critical for workflows that need to run at human-meaningful times. A "morning briefing at 8 AM" means nothing if your server is in a different timezone and you forget to specify. Use IANA timezone identifiers — they handle daylight saving transitions correctly.


Retry Logic and Error Handling

Every production Dispatch workflow needs explicit error handling. Without it, failures are silent — the workflow stops, nothing happens, and you do not know until you manually check the logs.

Configuring retries

{
  "name": "daily-report",
  "trigger": { "cron": "0 8 * * 1-5" },
  "retry": {
    "max_attempts": 3,
    "backoff": "exponential",
    "initial_delay": "30s",
    "max_delay": "5m"
  },
  "on_failure": {
    "notify": { "channel": "alerts", "message": "Daily report failed after 3 attempts" }
  }
}

Best practices for retry configuration:

Step-level error handling

Beyond workflow-level retries, you can configure error handling per step. This is useful when one step might fail (like an external API call) but subsequent steps should still run with default values:

{
  "name": "fetch-weather",
  "tool": "http-get",
  "params": { "url": "https://api.weather.example/today" },
  "on_error": {
    "action": "continue",
    "default_output": "Weather data unavailable"
  }
}

Resource Management and Staggering

Every Dispatch workflow execution consumes resources: model tokens, VRAM (if using local Ollama), API rate limit quota, and CPU. When you run multiple workflows, these resources compete.

Stagger your schedules

The most common mistake is scheduling everything at round numbers. If you have five daily workflows all set to 0 8 * * *, they all compete for resources at exactly 8:00 AM. Stagger them:

# Instead of:
0 8 * * *  # workflow A
0 8 * * *  # workflow B
0 8 * * *  # workflow C

# Use:
0 8 * * *   # workflow A
5 8 * * *   # workflow B (8:05)
10 8 * * *  # workflow C (8:10)

Five-minute gaps between workflows give each one time to complete before the next starts, avoiding VRAM contention on local models and API rate limit conflicts on cloud models.

Concurrency policies

Configure what happens when a scheduled run fires while the previous run is still executing:

Monitoring Scheduled Workflows

You cannot manage what you do not measure. For scheduled Dispatch workflows, monitoring means tracking three things:

Execution success rate

What percentage of scheduled runs complete successfully? A workflow that fails 10% of the time might seem acceptable, but over a month that is 3 failed runs — potentially 3 missed daily reports or 3 gaps in monitoring coverage.

Marketplace

Free skills and AI personas for OpenClaw — browse the marketplace.

Browse the Marketplace →

Execution duration

How long does each run take? If your daily report normally finishes in 30 seconds but one day takes 5 minutes, something changed — maybe the data source is returning more results, maybe the model is slower, maybe context is growing unbounded.

Token consumption

How many tokens does each workflow consume per run? Token costs are the hidden expense of Dispatch automation. A workflow that runs every 15 minutes and consumes 2,000 tokens per run burns 192,000 tokens per day. At $1 per million tokens, that is $0.19/day or $5.76/month — for a single workflow. Multiple workflows compound quickly.

OpenClaw's Dispatch system logs all three metrics by default. Review them weekly when you are first setting up automation, then monthly once workflows are stable. For the broader automation monitoring approach, see the automation scheduler guide.


Common Scheduling Patterns

Morning briefing (daily, weekdays)

{
  "trigger": { "cron": "0 7 * * 1-5", "timezone": "America/New_York" },
  "timeout": "120s",
  "retry": { "max_attempts": 2, "backoff": "exponential" }
}

Runs at 7 AM ET on weekdays. Two-minute timeout prevents a stuck model from blocking your morning. Two retries handle transient API failures.

Repository monitoring (every 30 minutes during work hours)

{
  "trigger": { "cron": "*/30 8-18 * * 1-5", "timezone": "America/New_York" },
  "concurrency": "skip",
  "timeout": "60s"
}

Checks every 30 minutes between 8 AM and 6 PM on weekdays. Skips if the previous run is still going. One-minute timeout keeps it snappy.

Weekly summary (every Friday afternoon)

{
  "trigger": { "cron": "0 16 * * 5", "timezone": "America/New_York" },
  "timeout": "300s",
  "retry": { "max_attempts": 3, "backoff": "exponential", "initial_delay": "60s" }
}

Runs Friday at 4 PM. Five-minute timeout because weekly summaries process more data. Three retries with longer initial delay for reliability.


Production Scheduling Checklist

Before deploying any scheduled Dispatch workflow to production, verify:

  • Timezone is explicit. Never rely on the server default. Set the timezone in the workflow definition.
  • Retry logic is configured. At minimum: 2-3 retries with exponential backoff.
  • Failure notifications are set. Route to a channel you actually monitor.
  • Timeout is defined. Every workflow should have a maximum execution time. 60 seconds for simple tasks, 300 seconds for complex ones.
  • Concurrency policy is set. Decide what happens when runs overlap.
  • Token budget is estimated. Calculate expected monthly token cost: tokens_per_run x runs_per_day x 30.
  • The workflow has been tested manually. Run it at least three times manually before scheduling it.
  • Schedules are staggered. No two heavy workflows should fire at the exact same time.

Common Mistakes to Avoid

  • Scheduling too frequently. Running a summary workflow every 5 minutes when daily is sufficient wastes tokens and adds noise. Start with the longest practical interval and shorten only if needed.
  • No timeout. A stuck model call without a timeout can block your workflow queue indefinitely. Always set an explicit timeout.
  • Ignoring token costs. That innocent-looking 15-minute workflow can cost $20+/month in API tokens. Monitor consumption from day one.
  • Round-number scheduling. Running everything at :00 creates resource contention. Stagger by 5-10 minutes.
  • No failure notification. If a workflow fails silently, you might not discover the problem for weeks. Notification is not optional for production workflows.
  • Testing only in production. Always test workflows manually before scheduling them. A workflow that fails immediately on its first automated run is a workflow that was never properly tested.

Frequently Asked Questions

What cron format does OpenClaw Dispatch use?

OpenClaw Dispatch uses standard five-field cron syntax: minute, hour, day-of-month, month, day-of-week. It also supports common shorthand expressions like @daily, @hourly, @weekly, and @monthly. Extended six-field syntax with seconds is not supported. All times are interpreted in the timezone configured in your OpenClaw instance settings.

How do I prevent overlapping Dispatch runs?

Add a concurrency policy to your workflow definition. Setting concurrency to "skip" tells Dispatch to skip a scheduled run if the previous run is still executing. Setting it to "queue" puts the new run in a queue. Setting it to "cancel" cancels the running execution and starts fresh. For most workflows, "skip" is the safest default because it prevents resource contention without losing data.

Can Dispatch handle timezone-aware scheduling?

Yes. OpenClaw Dispatch supports timezone specification in workflow definitions. You can set a timezone per workflow, overriding the instance default. This is important for workflows that need to run at specific local times — like a morning briefing at 8 AM in your timezone regardless of where your server is hosted. Use standard IANA timezone identifiers like America/New_York or Europe/London.

What is the minimum interval for Dispatch scheduling?

The minimum practical interval is one minute using the cron expression * * * * *. However, running AI-powered workflows every minute is usually wasteful — most workflows take 10-60 seconds to execute and consume model tokens on every run. For monitoring and health checks, 5-15 minute intervals are more practical. For reports and summaries, daily or weekly schedules are typical.