[Canonical page](<https://docs.dhtmlx.com/planning-engine/js/api/types/schedule-result/>)
[Full documentation index](<https://docs.dhtmlx.com/planning-engine/llms.txt>)


# ScheduleResult

The plain object returned by [`schedule`](<https://docs.dhtmlx.com/planning-engine/js/api/schedule.md>), [`Project#solve`](<https://docs.dhtmlx.com/planning-engine/js/api/project-solve.md>), [`Project#preview`](<https://docs.dhtmlx.com/planning-engine/js/api/project-preview.md>) and [`Project#analyze`](<https://docs.dhtmlx.com/planning-engine/js/api/project-analyze.md>). It lists the tasks whose dates changed, plus the conflicts, cycles and notes found in the plan. Analytics, overallocations and a load profile are added when requested or relevant.

Each call returns a fresh object with keys in sorted order. It shares nothing with the input or the project. Date fields are `"YYYY-MM-DD HH:MM"` strings, or local `Date` objects when the project was created with [`dates: "date"`](<https://docs.dhtmlx.com/planning-engine/js/api/project.md#projectoptions>).

## Fields

| Field | Type | Description |
|---|---|---|
| `baselineId` | `string` | Opaque token naming the accepted baseline. Present after `solve` and `level` (the baseline they accepted), after `preview` (the baseline it read), and after `analyze(null)` on a solved project with no pending edits. Absent otherwise, never `null`. |
| `updates` | [`Mutation`](<https://docs.dhtmlx.com/planning-engine/js/api/types/schedule-result.md#mutation>)`[]` | Tasks whose fields changed, in planning order, each with the changed fields only. With [`includeUnchanged`](<https://docs.dhtmlx.com/planning-engine/js/api/types/solve-options.md>) it also holds unchanged tasks with their dates and duration. |
| `cycles` | [`Cycle`](<https://docs.dhtmlx.com/planning-engine/js/api/types/schedule-result.md#cycle>)`[]` | One entry per dependency cycle. `[]` when there are none. |
| `conflicts` | [`Conflict`](<https://docs.dhtmlx.com/planning-engine/js/api/types/schedule-result.md#conflict>)`[]` | Constraint and calendar conflicts. Cycles aren't repeated here. |
| `notes` | [`Note`](<https://docs.dhtmlx.com/planning-engine/js/api/types/schedule-result.md#note>)`[]` | Records left out of the plan, and fixes made in `"repair"` validation mode. |
| `converged` | `boolean` | `false` when the planner didn't settle on stable dates. |
| `analytics` | [`Analytics`](<https://docs.dhtmlx.com/planning-engine/js/api/types/schedule-result.md#analytics>) | Present only when the call's options request analytics. |
| `overallocations` | [`Overallocation`](<https://docs.dhtmlx.com/planning-engine/js/api/types/overallocation.md>)`[]` | Present only when the project has assignments. |
| `profile` | [`LoadProfile`](<https://docs.dhtmlx.com/planning-engine/js/api/types/load-profile.md>) | Present only on a `preview` called with the `profile` option. |

A cycle, a conflict or `converged: false` isn't an error: the call still returns a result.

:::note
The leveling result is a `ScheduleResult` with an added `rounds` field; read `updates` on it. See [`Project#level`](<https://docs.dhtmlx.com/planning-engine/js/api/project-level.md#levelingresult>).
:::

### Mutation

One entry of `updates`. It uses the [`TaskData`](<https://docs.dhtmlx.com/planning-engine/js/api/types/task-data.md>) field names, so it can be passed back as a [`TaskUpdate`](<https://docs.dhtmlx.com/planning-engine/js/api/types/task-update.md>); `kind` and `reason` are ignored there.

| Field | Type | Description |
|---|---|---|
| `id` | [`Id`](<https://docs.dhtmlx.com/planning-engine/js/api/types/common.md#id>) | Task id. |
| `kind` | `"task" \| "summary" \| "milestone"` | Task type as scheduled. |
| `start_date` | [`DateValue`](<https://docs.dhtmlx.com/planning-engine/js/api/types/common.md#datevalue>) | New start. Present when changed. |
| `end_date` | [`DateValue`](<https://docs.dhtmlx.com/planning-engine/js/api/types/common.md#datevalue>) | New end. Present when changed. |
| `duration` | `number` | New duration in the task's `duration_unit`. Present when changed. |
| `leveling_delay` | `number` | New leveling delay, elapsed time in the task's `duration_unit`. Present when changed. |
| `pauses` | [`Pause`](<https://docs.dhtmlx.com/planning-engine/js/api/types/common.md#pause>)`[]` | The complete new list of pauses. Present when changed. |
| `reason` | [`Reason`](<https://docs.dhtmlx.com/planning-engine/js/api/types/schedule-result.md#reason>) | Why the task moved. Present only with `reasons: true`. |

A missing field means the value didn't change, not that it was cleared.

### Reason

Selected by `kind`:

| `kind` | Fields | Meaning |
|---|---|---|
| `"asap"` | `linkId`, `sourceId` | Pushed by the predecessor `sourceId` through link `linkId`. |
| `"alap"` | `linkId`, `targetId` | Pulled by the successor `targetId` through link `linkId`. |
| `"summary-translation"` | `summaryId` | Moved as a block with its summary `summaryId`. |
| `"constraint"` | none | Placed by its own hard constraint. |
| `"preferred"` | none | Kept at, or snapped to, its own date. |

### Cycle

| Field | Type | Description |
|---|---|---|
| `tasks` | [`Id`](<https://docs.dhtmlx.com/planning-engine/js/api/types/common.md#id>)`[]` | Tasks in the cycle. |
| `links` | [`Id`](<https://docs.dhtmlx.com/planning-engine/js/api/types/common.md#id>)`[]` | Links that close the cycle. |

### Conflict

Selected by `kind`:

| `kind` | Fields | Meaning |
|---|---|---|
| `"constraint-violation"` | `task`, `constraint`, `violation`, `required`, `actual` | The task breaks its `constraint` ([`ConstraintType`](<https://docs.dhtmlx.com/planning-engine/js/api/types/common.md#constrainttype>)). `violation` is `"earliest-start"`, `"latest-start"`, `"earliest-end"` or `"latest-end"`. `required` is the date the constraint asks for, `actual` the scheduled one. |
| `"calendar-non-working"` | `task`, `proposed`, `snapped` | The task's `proposed` date fell in non-working time and was moved to `snapped`. |

`required`, `actual`, `proposed` and `snapped` are [`DateValue`](<https://docs.dhtmlx.com/planning-engine/js/api/types/common.md#datevalue>)s.

### Note

Selected by `kind`:

| `kind` | Fields | Meaning |
|---|---|---|
| `"dropped-link"` | `link`, `reason` | The link was left out of the plan; `reason` is a message. |
| `"dropped-task"` | `task`, `reason` | The task was left out of the plan. |
| `"dropped-assignment"` | `assignment`, `reason` | The assignment was left out of the plan. |
| `"repaired"` | `path`, `message` | A fix made in `"repair"` validation mode; `path` points at the fixed input field. |

### Analytics

| Field | Type | Description |
|---|---|---|
| `status` | `"available" \| "invalid"` | `"invalid"` when cycles prevent the analysis; the other fields are then absent. |
| `criticalPath` | `{ tasks: Id[]; links: Id[] }` | Critical task ids in planning order, and the links that drive them with zero slack. Present when `criticalPath` was requested. |
| `slack` | `{ task: Id; total: number; free: number }[]` | Total and free slack per task, in `config.duration_unit`. Present when `slack` was requested. |

For how slack and the critical path are computed, see [Critical path and slack](<https://docs.dhtmlx.com/planning-engine/js/scheduling/critical-path-and-slack.md>).

## Used by

- [`schedule`](<https://docs.dhtmlx.com/planning-engine/js/api/schedule.md>): returns it, always with string dates
- [`Project#solve`](<https://docs.dhtmlx.com/planning-engine/js/api/project-solve.md>): returns it for the newly accepted baseline
- [`Project#preview`](<https://docs.dhtmlx.com/planning-engine/js/api/project-preview.md>): returns it for the previewed changes, relative to the baseline
- [`Project#analyze`](<https://docs.dhtmlx.com/planning-engine/js/api/project-analyze.md>): returns it without updates or planner conflicts
- [`Project#level`](<https://docs.dhtmlx.com/planning-engine/js/api/project-level.md>): returns it with an added `rounds` field

## Example

A `solve` result with `reasons: true` on a project with one link and two assigned tasks:

```js
{
  baselineId: "1-ed3638c479bf1963",
  conflicts: [],
  converged: true,
  cycles: [],
  notes: [],
  overallocations: [],
  updates: [
    {
      end_date: "2026-08-13 08:00",
      id: 2,
      kind: "task",
      reason: { kind: "asap", linkId: 1, sourceId: 1 },
      start_date: "2026-08-12 08:00",
    },
  ],
}
```

## Related

- [`Project#solve`](<https://docs.dhtmlx.com/planning-engine/js/api/project-solve.md>) - the main call that returns it
- [`TaskUpdate`](<https://docs.dhtmlx.com/planning-engine/js/api/types/task-update.md>) - feeding an update entry back
- [`Overallocation`](<https://docs.dhtmlx.com/planning-engine/js/api/types/overallocation.md>) - the `overallocations` entries
- [Reading results](<https://docs.dhtmlx.com/planning-engine/js/scheduling/reading-results.md>) - applying `updates` to an application model
- [Critical path and slack](<https://docs.dhtmlx.com/planning-engine/js/scheduling/critical-path-and-slack.md>) - requesting and reading `analytics`
