Resource Schedules
Resource Schedules enable time-based auto-stop and auto-start of platform resources to reduce costs during off-hours. Schedules can be scoped to the entire platform, a specific user, or a resource group, providing flexible cost optimization across environments.
Schedule Structure
Each schedule consists of the following components:
Scope
Schedules are scoped to one of three levels:
| Scope Level | Description |
|---|---|
platform | Applies to all resources across the entire platform |
user | Applies to resources owned by a specific user |
resourceGroup | Applies to resources within a specific resource group |
The scope object includes:
| Field | Description |
|---|---|
level | One of platform, user, or resourceGroup |
userId | User ID (for user-scoped schedules) |
userName | Display name of the user (cached) |
resourceGroupId | Resource group ID (for group-scoped schedules) |
resourceGroupName | Display name of the group (cached) |
Schedule Configuration
| Field | Description |
|---|---|
timezone | IANA timezone string (e.g., America/New_York, UTC) |
stopTime | Time to stop resources (e.g., 19:00) |
startTime | Time to start resources (e.g., 08:00) |
daysOfWeek | Array of active day numbers (0 = Sunday, 1 = Monday, ..., 6 = Saturday) |
Schedule Status
| Status | Description |
|---|---|
active | Schedule is enabled and will execute at configured times |
paused | Schedule is temporarily suspended (preserves configuration) |
disabled | Schedule is disabled and not tracking or executing |
Tracking Fields
| Field | Description |
|---|---|
lastStopAt | When resources were last stopped by this schedule |
lastStartAt | When resources were last started by this schedule |
nextStopAt | Next scheduled stop time |
nextStartAt | Next scheduled start time |
Creating a Schedule
Via the UI
- Navigate to FinOps then Resource Schedules
- Click Create Schedule
- Configure the schedule:
Basic Information:
- Name -- Descriptive name (e.g., "Dev Environment Weeknight Shutdown")
- Description -- Optional description of the schedule's purpose
Scope:
- Platform -- Applies to all platform resources
- User -- Select a specific user from the dropdown
- Resource Group -- Select a resource group from the dropdown
Schedule Configuration:
- Timezone -- Select the timezone for stop/start times
- Stop Time -- When to stop resources (e.g., 7:00 PM)
- Start Time -- When to start resources (e.g., 8:00 AM)
- Days of Week -- Select which days the schedule applies to
- Click Create Schedule
Schedule Methods
| Method | Parameters | Description |
|---|---|---|
schedules.create | { name, description, scope, schedule, enabled } | Create a new schedule |
schedules.get | scheduleId | Get a schedule by ID |
schedules.list | { scopeLevel, status, search, skip, limit } | List schedules with filters |
schedules.update | scheduleId, { name, description, scope, schedule, enabled } | Update a schedule |
schedules.delete | scheduleId | Delete a schedule |
All schedule methods require admin role access.
Managing Schedules
Filtering and Searching
The schedule list supports the following filters:
- Scope Level -- Filter by
platform,user,resourceGroup, orall - Status -- Filter by
active,paused,disabled, orall - Search -- Text search on schedule name (case-insensitive, regex-safe)
- Pagination --
skipandlimitfor paging through results
Results are sorted by creation date (newest first).
Pausing and Resuming
Temporarily disable a schedule without deleting it:
Pause:
schedules.pause(scheduleId)
Sets enabled: false and status: 'paused'. The schedule stops executing stop/start actions.
Resume:
schedules.resume(scheduleId)
Sets enabled: true and status: 'active'. The schedule resumes executing at configured times.
Execute Now
Manually trigger a stop or start action immediately:
schedules.executeNow(scheduleId, action)
| Parameter | Description |
|---|---|
scheduleId | The schedule to execute |
action | Either stop or start |
This creates an execution log entry with triggeredBy: 'manual' and status: 'pending'.
Execution History
View the execution history for a schedule:
schedules.getHistory(scheduleId, limit = 50)
Returns the most recent execution log entries, sorted with newest first. Each entry includes:
| Field | Description |
|---|---|
action | stop or start |
executedAt | When the action was executed |
triggeredBy | scheduled (automatic) or manual (user-initiated) |
status | success, failed, or pending |
resourcesAffected | Number of resources or array of resource IDs affected |
errorMessage | Error details if the execution failed |
Override Management
Overrides allow you to exempt specific resources from a schedule's stop/start actions. This is useful for excluding critical resources that must remain running.
Adding an Override
schedules.addOverride(scheduleId, override)
| Field | Description |
|---|---|
resourceType | Type of resource to exempt |
resourceId | ID of the resource to exempt |
skipUntil | Date until which the override is active |
reason | Optional reason for the override |
The override is automatically attributed to the user who created it, with a creation timestamp recorded.
Removing an Override
schedules.removeOverride(scheduleId, resourceType, resourceId)
Removes the override matching the specified resource type and ID from the schedule.
Schedule Examples
Development Environment -- Weeknight Shutdown
Stop development resources after business hours and restart them in the morning:
- Scope: Resource Group ("Development Environment")
- Timezone: America/New_York
- Stop Time: 7:00 PM
- Start Time: 8:00 AM
- Days of Week: Monday through Friday (1-5)
- Potential Savings: 60-70% on development compute costs
With this schedule, development resources run 11 hours per day on weekdays and are stopped on weekends, significantly reducing compute costs.
Staging Environment -- Extended Hours
Keep staging resources running during extended business hours but stop overnight:
- Scope: Resource Group ("Staging Environment")
- Timezone: UTC
- Stop Time: 10:00 PM
- Start Time: 6:00 AM
- Days of Week: Monday through Saturday (1-6)
- Potential Savings: 30-40% on staging compute costs
User-Level Development Budget Protection
Automatically stop resources for a specific developer during off-hours:
- Scope: User (specific developer)
- Timezone: America/Los_Angeles
- Stop Time: 6:00 PM
- Start Time: 9:00 AM
- Days of Week: Monday through Friday (1-5)
Platform-Wide Weekend Shutdown
Stop all non-production resources on weekends:
- Scope: Platform
- Stop Time: 8:00 PM Friday
- Start Time: 7:00 AM Monday
- Days of Week: Monday through Friday (1-5)
Use overrides to exempt any resources that must remain running over the weekend.
Storage and Filtering
Schedules are stored in the platform and can be filtered by scope level, status, enabled state, and upcoming stop/start times.
Combining Schedules with Budgets
For maximum cost control, combine resource schedules with budgets:
- Set schedules to automatically reduce costs during off-hours
- Set budgets to catch unexpected spending that exceeds schedule savings
- Configure budget thresholds based on expected post-schedule spending levels
For example, if a development environment costs $100/day at full utilization, and a schedule reduces runtime to 11 hours/day on weekdays only, expected monthly cost drops from ~$3,000 to ~$1,000. Set the budget at $1,200/month with an alert at 80% ($960) to catch any anomalies.
Best Practices
Start with Development Environments
Development resources typically have the most flexibility for scheduling. Start here for immediate savings before applying schedules to staging or shared environments.
Use Overrides for Critical Resources
Always add overrides for resources that must remain available:
- Long-running batch jobs that span off-hours
- Resources needed for overnight deployments or testing
- Shared services used by teams in different time zones
Set Appropriate Timezones
Choose timezones that match the working hours of the team using the resources. For globally distributed teams, consider using UTC and setting stop/start times that accommodate all time zones.
Monitor Execution History
Review execution logs regularly to ensure schedules are working correctly:
- Check for failed executions that may indicate resource issues
- Verify that the correct number of resources are being affected
- Investigate any unexpected manual executions
Coordinate with Team Schedules
Communicate schedule changes to affected teams. Unexpected resource shutdowns can disrupt work if team members are unaware of the schedule.
Resource schedules will stop running resources at the configured stop time. Ensure that no critical workloads are running during scheduled stop windows, or add overrides for resources that must remain available.