How to automate a Daily Report with an AI agent
Run your agent headless on a schedule. Use claude -p or codex exec from cron, or set up a scheduled Cursor Automation. Write the prompt once, limit the tools it may use, and have it save the report to a file or send it to you for review rather than straight to other people.
Checked against official docs on Oct 26, 2026.
Get the free starter kit. One short email a day when our setups change.
Free starter kit on signup: 2 Claude Code skills and 1 agent persona from our paid packs. By subscribing you agree to get The AI Loadout Daily, one email each morning. No spam, we never sell your email, and every email has a one-click unsubscribe link.
Claude Code
Test the prompt: claude -p "Read data/sales.csv and write a 5 line summary to reports/today.md" --allowedTools "Read,Write"Add it to cron: 0 8 * * * cd ~/reports && claude -p "..." --allowedTools "Read,Write"Add --bare to skip hooks, plugins and MCP discovery when you want faster, repeatable runs
Codex
Test: codex exec "summarize data/sales.csv into reports/today.md"Schedule the same command with cron or your CISee the codex exec reference for sandbox and approval flags
Cursor
Install the CLI: curl https://cursor.com/install -fsS | bashTest: agent -p "summarize data/sales.csv" --output-format textOr create a Cursor Automation with a schedule trigger
Grok Bot
Ask Grok Bot to run the report every weekday morningIt sets up a routine and sends you the resultChange or stop it by asking
Gotchas
- cron runs with a bare PATH. Use full paths to claude, codex or agent.
- Headless runs skip approval prompts, so restrict tools tightly.
- Each run costs tokens. A daily report on a big file adds up.
The loadout for this job
- Tools: Claude, ChatGPT
- Repo: OpenAI Codex CLI
- Model: Claude Sonnet 5.5
- Bot: Grok Bot
- Full setup: Best AI setup for data analysis
FAQ
How do I run Claude Code on a schedule?
Call claude -p with your prompt from cron or a CI job, and limit tools with --allowedTools.
What is codex exec?
Codex's non-interactive mode for scripts and CI.
Related how-tos
Sources
Commands change. Check the linked docs before you run anything. All how-to guides