Scheduling
ModelReins supports scheduled jobs that run automatically at defined intervals. Useful for recurring tasks like daily summaries, periodic code scans, or batch processing.
Creating a schedule
Section titled “Creating a schedule”Schedules are created in the dashboard at app.modelreins.com (Schedules tab) or via the API.
Cron-based example (API):
curl -X POST https://app.modelreins.com/api/schedules \ -H "Authorization: Bearer $MODELREINS_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "name": "daily-summary", "cron": "0 9 * * *", "prompt": "Summarize yesterday's git commits", "provider": "ollama" }'Interval-based example (API):
curl -X POST https://app.modelreins.com/api/schedules \ -H "Authorization: Bearer $MODELREINS_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "name": "health-check", "interval": "30m", "prompt": "Check these endpoints and report any failures" }'Managing schedules
Section titled “Managing schedules”Use the dashboard Schedules tab or the API:
| Action | Dashboard | API |
|---|---|---|
| List all | Schedules tab | GET /api/schedules |
| Pause | Toggle on schedule card | PUT /api/schedules/:name with {"status":"paused"} |
| Resume | Toggle on schedule card | PUT /api/schedules/:name with {"status":"active"} |
| Delete | Delete button | DELETE /api/schedules/:name |
| View history | Click schedule → Runs tab | GET /api/schedules/:name/history |
Scheduled jobs follow the same routing rules as manually dispatched jobs.