Guides
Schedules
Automate server tasks with scheduled actions
Schedules
Schedules allow you to automate server tasks like backups, restarts, and commands.
Schedule Types
| Action | Description |
|---|---|
| Command | Send a console command |
| Power | Start, stop, restart, or kill |
| Backup | Create a backup |
Creating a Schedule
- Navigate to Server → Schedules
- Click Create Schedule
- Configure the schedule:
- Name
- Cron expression
- Action type
- Action parameters
- Click Save
Cron Expressions
Schedules use cron syntax with 5 fields:
┌───────────── minute (0-59)
│ ┌───────────── hour (0-23)
│ │ ┌───────────── day of month (1-31)
│ │ │ ┌───────────── month (1-12)
│ │ │ │ ┌───────────── day of week (0-7)
│ │ │ │ │
* * * * *Special Characters
| Character | Description |
|---|---|
* | Any value |
, | List separator |
- | Range |
/ | Step values |
Examples
| Expression | Description |
|---|---|
0 * * * * | Every hour |
*/15 * * * * | Every 15 minutes |
0 0 * * * | Daily at midnight |
0 2 * * * | Daily at 2 AM |
0 0 * * 0 | Weekly on Sunday |
0 0 1 * * | Monthly on the 1st |
0 6,18 * * * | At 6 AM and 6 PM |
Action: Command
Send a command to the server console.
Example: Save World
{
"name": "Auto Save",
"cron": "*/30 * * * *",
"action": "command",
"payload": {
"command": "save-all"
}
}Example: Broadcast Message
{
"name": "Restart Warning",
"cron": "55 3 * * *",
"action": "command",
"payload": {
"command": "say Server restarting in 5 minutes!"
}
}Action: Power
Control server power state.
Example: Daily Restart
{
"name": "Daily Restart",
"cron": "0 4 * * *",
"action": "power",
"payload": {
"action": "restart"
}
}Power Actions
| Action | Description |
|---|---|
start | Start the server |
stop | Gracefully stop |
restart | Stop then start |
kill | Force terminate |
Action: Backup
Create a server backup.
Example: Hourly Backup
{
"name": "Hourly Backup",
"cron": "0 * * * *",
"action": "backup",
"payload": {
"name": "scheduled-{timestamp}",
"ignore": ["logs/*"]
}
}Chained Tasks
Execute multiple actions in sequence:
Example: Restart Sequence
-
5 min warning -
55 3 * * *say Server restarting in 5 minutes! -
1 min warning -
59 3 * * *say Server restarting in 1 minute! -
Save world -
59 3 * * *(+30s)save-all -
Restart -
0 4 * * *power: restart
Schedule Management
Enable/Disable
Toggle schedules without deleting:
- Navigate to Schedules
- Click the toggle switch
- Schedule is now disabled/enabled
Run Now
Manually trigger a schedule:
- Navigate to Schedules
- Click the Run button
- Action executes immediately
View History
See past executions:
- Navigate to Schedules
- Click on a schedule
- View Execution History
API Access
List Schedules
curl https://api.example.com/api/v1/servers/{serverId}/schedules \
-H "Authorization: Bearer $TOKEN"Create Schedule
curl -X POST https://api.example.com/api/v1/servers/{serverId}/schedules \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "Daily Restart",
"cron": "0 4 * * *",
"action": "power",
"payload": { "action": "restart" },
"enabled": true
}'Best Practices
- Stagger Restarts - Don't restart all servers at once
- Warn Players - Send messages before disruptive actions
- Off-Peak Hours - Schedule maintenance during low usage
- Test First - Use "Run Now" to verify schedules work
- Monitor Execution - Check history for failures