DenchClaw Cron Scheduling: Automate Recurring Tasks
How to use DenchClaw's cron scheduling to automate recurring CRM tasks — lead enrichment, follow-up reminders, data cleanup, and more.
DenchClaw Cron Scheduling: Automate Recurring Tasks
DenchClaw's cron system lets you schedule AI tasks that run automatically on a recurring schedule. Daily pipeline summaries, weekly follow-up reminders, monthly data cleanup, anniversary alerts — anything you'd do manually on a recurring basis can be automated with a natural language instruction and a schedule.
Cron jobs in DenchClaw are different from traditional shell crons: the scheduled task runs inside an AI session with full access to your CRM data, so it can query, update, draft, and notify — not just run a script.
Creating a Cron Job#
The simplest way to create a cron: just tell DenchClaw.
"Every weekday at 8am, send me a Telegram message with my pipeline summary and any deals with upcoming close dates."
DenchClaw creates a cron job with:
- Schedule: weekdays at 8am in your timezone
- Task: query your deals, format a summary, send to Telegram
"On the first of every month, run a cleanup to find contacts with missing email addresses and create a task for me to follow up on each one."
"Every Monday, check which clients have contracts expiring in the next 60 days and send me the list."
"On the anniversary of each client's start date, message me to send them a check-in."
Each of these becomes a persistent cron job that runs automatically.
Cron Schedule Syntax#
DenchClaw accepts both natural language schedules and standard cron syntax:
Natural language:
- "every morning at 8am"
- "every Monday at 9am"
- "on the first of every month"
- "every weekday at noon"
- "every 2 hours"
- "at 5pm every Friday"
- "every 30 minutes"
Cron syntax (also accepted):
0 8 * * 1-5 # 8am weekdays
0 8 * * 1 # 8am Monday
0 0 1 * * # Midnight first of month
0 12 * * 1-5 # Noon weekdays
*/30 * * * * # Every 30 minutes
Managing Cron Jobs#
Via AI chat#
"Show me all my scheduled tasks." — AI lists all active cron jobs with their schedules and last run status.
"Pause the morning pipeline summary." — AI disables the cron without deleting it.
"Delete the monthly cleanup cron." — AI removes the cron job.
"Change the morning summary to 7am instead of 8am." — AI updates the schedule.
Via the Cron Manager panel#
Navigate to Settings → Automation → Scheduled Tasks to see all cron jobs in a management interface:
- Enable/disable toggle
- Last run status and output
- Next scheduled run
- Edit schedule
- Delete
Via cron storage file#
Cron configurations are stored in ~/.openclaw-dench/workspace/crons.yaml:
crons:
- id: morning-pipeline-summary
name: Morning Pipeline Summary
schedule: "0 8 * * 1-5" # 8am weekdays
task: |
Query v_deals for all open deals with close dates this week.
Format a concise summary: deal name, stage, value, close date.
Include total pipeline value.
Send to Telegram.
enabled: true
lastRun: "2026-03-25T08:00:02Z"
lastStatus: success
- id: contract-renewal-check
name: Contract Renewal Check
schedule: "0 9 * * 1" # 9am Mondays
task: |
Query v_clients for active clients with Contract End Date
within 60 days.
Format a list with client name, contract end date, and monthly value.
Send to Telegram if any results found.
enabled: trueYou can edit this file directly to modify cron task descriptions.
Cron Task Capabilities#
What a cron task can do (the task runs as a full AI session):
Query CRM data:
Query all deals in the pipeline, group by stage,
return count and total value per stage.
Update CRM records:
Find all contacts with Last Contacted > 30 days.
Create a follow-up task for each one assigned to the primary user.
Send notifications:
Draft and send a Telegram message with today's renewal alerts.
Run browser actions:
Open LinkedIn and check for new connection requests.
Save any new connections as Contacts in DenchClaw.
Draft content:
Pull all closed won deals this week.
Draft a weekly wins summary email to send to the team.
Trigger webhooks:
Post to the Slack #pipeline-updates webhook with today's deal activity.
Using dench.cron in Apps#
Custom Dench Apps can schedule cron jobs via the bridge API:
// Create a cron from within an app
const cron = await dench.cron.schedule({
name: "Refresh Lead Scores",
everyMs: 3600000, // Every hour
task: `
For each person with Status = 'Lead' and no Lead Score,
query their company size and website to estimate a lead score.
Update the Lead Score field with 1-10 rating.
`
});
// List active crons
const crons = await dench.cron.list();
// Pause a cron
await dench.cron.pause(cron.id);
// Delete a cron
await dench.cron.delete(cron.id);Timezone Handling#
Cron schedules in DenchClaw use your workspace's configured timezone:
# In settings.yaml
timezone: "America/Los_Angeles"Natural language schedule creation automatically uses this timezone. "Every morning at 8am" means 8am in your configured timezone, not UTC.
Error Handling and Retry#
If a cron job fails (network error, AI API error, database error):
- DenchClaw logs the error with full output
- The cron is retried after a configurable delay (default: 15 minutes)
- After 3 consecutive failures, the cron is paused and you're notified
View recent cron run logs in Settings → Automation → Scheduled Tasks → History.
Common Cron Templates#
Here are ready-to-use cron templates for common use cases:
Daily morning briefing: "Every weekday at 7:30am, send me a Telegram message with: (1) tasks due today, (2) deals closing this week, (3) any contacts needing follow-up."
Weekly pipeline review: "Every Monday at 9am, query all open deals and send me a pipeline summary sorted by close date."
Contract renewal alerts: "Every Monday morning, check for client contracts expiring in the next 60 days and send me the list."
Birthday/anniversary reminders: "Every morning, check for contacts with birthdays today and send me their names so I can reach out."
Data quality check: "On the first of every month, find contacts missing email addresses and create a follow-up task for each."
See also: DenchClaw Notifications for how cron results are delivered, and DenchClaw Webhooks for triggering external services from crons.
Frequently Asked Questions#
Does DenchClaw need to be running for cron jobs to execute?#
Yes. DenchClaw's cron runner requires the local server (OpenClaw gateway) to be running. If your Mac is asleep or DenchClaw is stopped, cron jobs that were scheduled during that time run on next startup with a note that they were delayed. For 24/7 cron reliability, run DenchClaw on a server (cloud instance, NAS, or a dedicated machine).
Can a cron job take longer than its interval?#
Cron jobs include a timeout setting (default: 5 minutes). If a cron exceeds the timeout, it's killed and marked as failed. For long-running tasks, use a less frequent schedule or restructure the task to work in smaller increments.
Can I run a cron job immediately without waiting for the schedule?#
Yes. In the cron management panel, click "Run now" on any cron job to execute it immediately. Useful for testing a new cron before its first scheduled run.
How do cron jobs interact with my active session?#
Cron jobs run in isolated sessions, separate from your main chat. They don't appear in your chat history and don't interrupt active conversations. Results are delivered via notifications or messaging channels, not into your current session.
Is there a limit to how many cron jobs I can create?#
No hard limit, but resource-intensive crons (frequent intervals, complex AI tasks) consume API tokens and CPU. A practical limit for most users is 10-20 active crons at varying frequencies. Monitor your API usage if you have many active crons.
Ready to try DenchClaw? Install in one command: npx denchclaw. Full setup guide →
