Docs
  • Solver
  • Models
    • Field Service Routing
    • Employee Shift Scheduling
    • Pick-up and Delivery Routing
    • Task Scheduling
  • Platform
Try models
  • Task Scheduling
  • Machine and employee resource constraints
  • Employee resources

Task Scheduling

    • Introduction
    • Getting started: Hello world
    • User guide
      • Terminology
      • Scheduling API concepts
      • Integration
      • Constraints
      • Using the API
        • Using the OpenAPI spec
        • API tooling
      • Demo datasets
      • Input datasets
        • Model configuration
        • Model input
      • Output datasets
        • Metadata
        • Model output
        • Input metrics
        • Key performance indicators (KPIs)
      • Job types and machine types
      • Resource-specific durations
      • Freeze jobs until
      • Metrics and optimization goals
      • Score analysis
      • Validation
    • Machine and employee resource constraints
      • Machine unavailability
      • Resource transitions
      • Employee resources
    • Job service constraints
      • Time windows
      • Time management
      • Job dependencies
      • Priority jobs
      • Tags and specific resources
    • Real-time planning
    • Changelog
    • Upgrading to the latest versions
    • Feature requests

Employee resources

In addition to machines, the Task Scheduling model supports employees. Employees can be scheduled to perform jobs, with support for skills and availability.

1. Basic employee usage

Employees and machines are defined separately and can both be assigned jobs:

{
  "employees": [
    {
      "id": "Employee 1",
      "start": "2024-12-01T08:00:00+00:00"
    },
    {
      "id": "Employee 2",
      "start": "2024-12-01T08:00:00+00:00"
    }
  ],
  "jobs": [
    {
      "id": "Job 1",
      "duration": "PT2H"
    },
    {
      "id": "Job 2",
      "duration": "PT3H"
    }
  ]
}

The solver will assign jobs to either employees or machines (if both are present) based on availability and constraints.

2. Employees and machines together

You can use both employees and machines in the same schedule. This is useful for modeling scenarios where some jobs can be done by either machines or employees:

{
  "machines": [
    {
      "id": "Machine A",
      "start": "2024-12-01T00:00:00+00:00"
    }
  ],
  "employees": [
    {
      "id": "Operator 1",
      "start": "2024-12-01T08:00:00+00:00"
    }
  ],
  "jobs": [
    {
      "id": "Automated job",
      "duration": "PT4H",
      "requiredResources": ["Machine A"]
    },
    {
      "id": "Manual job",
      "duration": "PT2H",
      "requiredResources": ["Operator 1"]
    },
    {
      "id": "Flexible job",
      "duration": "PT1H"
    }
  ]
}

In this example:

  • The automated job can only be assigned to Machine A.

  • The manual job can only be assigned to Operator 1.

  • The flexible job can be assigned to either Machine A or Operator 1.

3. Employee skills with tags

Employees can have skills modeled as tags:

{
  "employeeTags": [
    { "id": "Welding" },
    { "id": "Certified" },
    { "id": "Senior" }
  ],
  "employees": [
    {
      "id": "Employee 1",
      "start": "2024-12-01T08:00:00+00:00",
      "tags": [
        { "tagId": "Welding" },
        { "tagId": "Certified" }
      ]
    },
    {
      "id": "Employee 2",
      "start": "2024-12-01T08:00:00+00:00",
      "tags": [
        { "tagId": "Welding" },
        { "tagId": "Senior" }
      ]
    }
  ],
  "jobs": [
    {
      "id": "Certified welding job",
      "duration": "PT3H",
      "requiredTags": ["Welding", "Certified"]
    }
  ]
}

This job can only be assigned to Employee 1, who has both the Welding and Certified skills.

For more information on tags, see Tags and specific resources.

4. Employee unavailability

Employees can have unavailable time spans for breaks, meetings, or other activities:

{
  "employees": [
    {
      "id": "Employee 1",
      "start": "2024-12-01T08:00:00+00:00",
      "unavailableTimeSpans": [
        {
          "start": "2024-12-01T12:00:00+00:00",
          "end": "2024-12-01T13:00:00+00:00"
        },
        {
          "start": "2024-12-01T15:00:00+00:00",
          "end": "2024-12-01T15:15:00+00:00"
        }
      ]
    }
  ],
  "jobs": [
    {
      "id": "Long job",
      "duration": "PT6H"
    }
  ]
}

If the Long job starts at 10:00, it will be paused during the lunch break (12:00-13:00) and the afternoon break (15:00-15:15), extending the completion time to 17:15.

5. Skill availability over time

Employee skills can be available only during specific time periods, which is useful for modeling temporary certifications or shift-based capabilities:

{
  "employees": [
    {
      "id": "Employee 1",
      "start": "2024-12-01T08:00:00+00:00",
      "tags": [
        {
          "tagId": "Forklift",
          "timeSpans": [
            {
              "start": "2024-12-01T08:00:00+00:00",
              "end": "2024-12-01T12:00:00+00:00"
            }
          ]
        }
      ]
    }
  ],
  "jobs": [
    {
      "id": "Forklift job",
      "duration": "PT1H",
      "requiredTags": ["Forklift"]
    }
  ]
}

This models an employee who can only operate a forklift during the morning shift (08:00-12:00). The Forklift job must be scheduled during this time window.

6. Resource-specific job durations for employees

Different employees have different levels of proficiency and work at different speeds:

{
  "employees": [
    {
      "id": "Senior technician",
      "start": "2024-12-01T08:00:00+00:00"
    },
    {
      "id": "Junior technician",
      "start": "2024-12-01T08:00:00+00:00"
    },
    {
      "id": "Apprentice",
      "start": "2024-12-01T08:00:00+00:00"
    }
  ],
  "jobs": [
    {
      "id": "Eepair job",
      "duration": "PT4H",
      "durationOnResources": [
        {
          "resource": "Senior technician",
          "duration": "PT2H"
        },
        {
          "resource": "Junior technician",
          "duration": "PT4H"
        },
        {
          "resource": "Apprentice",
          "duration": "PT6H"
        }
      ]
    }
  ]
}

The same repair job takes:

  • Two hours for the senior technician.

  • Four hours for the junior technician (default duration).

  • Six hours for the apprentice.

For more information, see Resource-specific durations.

7. Employee-to-employee transitions

Resource transitions allow you to model transitions between employees, for instance, for the trainer to provide training, and then the trainee to perform supervised work:

{
  "employees": [
    {
      "id": "Trainer",
      "start": "2024-12-01T08:00:00+00:00"
    },
    {
      "id": "Trainee",
      "start": "2024-12-01T08:00:00+00:00"
    }
  ],
  "jobs": [
    {
      "id": "Training session",
      "duration": "PT2H"
    },
    {
      "id": "Supervised work",
      "duration": "PT4H",
      "dependencies": [
        { "id": "Training session" }
      ]
    }
  ],
  "resourceTransitions": [
    {
      "fromResourceId": "Trainer",
      "toResourceId": "Trainee",
      "reward": 100
    }
  ]
}

8. Real-time planning with employees

Employees can be pinned to jobs for real-time planning:

{
  "employees": [
    {
      "id": "Employee 1",
      "start": "2024-12-01T08:00:00+00:00",
      "jobs": [
        {
          "id": "Ongoing job",
          "start": "2024-12-01T08:00:00+00:00"
        }
      ],
      "freezeJobsUntil": "2024-12-01T10:00:00+00:00"
    }
  ],
  "jobs": [
    {
      "id": "Ongoing job",
      "duration": "PT4H"
    },
    {
      "id": "New job",
      "duration": "PT2H"
    }
  ]
}

All jobs for Employee 1 that start before 10:00 will be pinned (frozen) in place during re-planning.

For more information on pinning, see Real-time planning and Freeze jobs until.

Next

  • See the full API spec or try the online API.

  • Learn about tags and specific resources.

  • Learn about unavailability.

  • © 2026 Timefold BV
  • Timefold.ai
  • Documentation
  • Changelog
  • Send feedback
  • Privacy
  • Legal
    • Light mode
    • Dark mode
    • System default