Skip to main content
Workflows can run on a schedule using cron expressions defined in schedules.json. The platform registers schedules during deployment and triggers workflow submissions automatically.

Configuration

Define schedules in schedules.json at the root of your app:
{
  "schedules": [
    {
      "name": "daily-order-sync",
      "cron": "0 3 * * *",
      "timezone": "UTC",
      "skipIfRunning": true,
      "workflow": "./src/server/workflows/syncOrders.ts",
      "params": {
        "orgId": "org_abc123",
        "appId": "my-app"
      }
    }
  ]
}
FieldDescription
nameUnique schedule identifier
cronCron expression for the schedule
timezoneTimezone for the cron expression (default: "UTC")
skipIfRunningIf true, skip the scheduled run when a previous run is still active
workflowPath to the workflow file
paramsVariable values passed to the workflow

Common cron expressions

ExpressionSchedule
0 * * * *Every hour
0 */6 * * *Every 6 hours
0 3 * * *Daily at 3:00 AM
0 0 * * 1Weekly on Monday at midnight
0 0 1 * *Monthly on the 1st at midnight
*/15 * * * *Every 15 minutes

Preventing overlapping runs

Set skipIfRunning: true to avoid starting a new run when the previous one hasn’t finished. This is recommended for long-running workflows where concurrent execution could cause data conflicts or duplicate processing.

Build-time validation

The app framework’s build pipeline validates schedules.json during the build phase:
  • Cron expressions are syntactically valid
  • Workflow file paths resolve to exported workflow definitions
  • Parameter values match the workflow’s variable definitions
  • Schedule names are unique

Manual triggers

Scheduled workflows can also be triggered manually through the app’s API or UI. The same workflow definition is used — only the submission source differs (scheduled vs. manual).