Each item — Tempus schedule template as serialized by the `ScheduleResource`. A schedule
defines a recurring planning grid: which weekdays it covers, the daily working
window (start and end time), and the granularity of each bookable slot. It
optionally pins a default status and sub-status applied to generated entries, and
can restrict the statuses selectable on the grid.
A schedule also defines WHO it is for, via `scopeType`: whole companies, one or
more departments, or a hand-picked list of employees. `scope` reports the raw
selection (only the list matching `scopeType` is populated), while `departments`
and `employees` report the resolved coverage. `employees` is the definitive list of
people who may be booked into the schedule's slots, and is what an assignment
picker should be built from.
This object documents the exact keys returned by the resource, not the raw
database columns. The `department`, `status`, and `subStatus` fields are
relationship objects that are only present when the corresponding relation is
eager-loaded on the model; when not loaded they are omitted from the payload
entirely. The `dayStartTime` and `dayEndTime` values are returned trimmed to
`HH:MM` (seconds are dropped). Times are local wall-clock values with no
timezone component.
id*string · uuid
Unique schedule identifier.
read-only
example: 550e8400-e29b-41d4-a716-446655440000
name*string
Human-readable name of the schedule template.
example: Sales Team Weekly Plan
departmentobject | null
The schedule's anchor department. Only present when the `department` relation is
eager-loaded; otherwise this key is omitted.
Null when the scope resolves to no department at all, which happens for a
company-scoped schedule whose people hold contracts carrying no department. Such
a schedule is valid and fully usable: its people come from the company. Treat
this field as optional. Use `departments` for the full list of departments the
schedule covers.
idstring · uuid
Unique identifier of the department.
example: 550e8400-e29b-41d4-a716-446655440001
namestring
Display name of the department.
example: Customer Support
scopeType*string
Who the schedule is for:
- `company`: everyone contracted with the selected companies.
- `department`: everyone contracted in the selected departments (the default,
and what a schedule created without a `scope_type` gets).
- `employees`: exactly the selected people, who may come from different
departments and different companies.
enum: company department employees
example: department
scope*object
The raw selection the schedule was configured with. Only the list matching `scopeType` is populated; the other two are empty arrays. Use this to pre-populate an edit form so it round-trips.
companies*array<object>
Selected companies. Populated only when `scopeType` is `company`.
id*string · uuid
Unique identifier of the company.
example: 550e8400-e29b-41d4-a716-446655440020
name*string
Display name of the company.
example: Northwind Trading
departments*array<object>
Selected departments. Populated only when `scopeType` is `department`.
id*string · uuid
Unique identifier of the department.
example: 550e8400-e29b-41d4-a716-446655440001
name*string
Display name of the department.
example: Customer Support
employees*array<object>
Selected employees. Populated only when `scopeType` is `employees`.
id*string · uuid
Unique identifier of the employee.
example: 550e8400-e29b-41d4-a716-446655440010
fullName*string
Display name of the employee.
example: Jane Smith
departments*array<object>
Every department the schedule covers, resolved from the scope. For a company scope these are the companies' departments; for an employee scope the departments on the selected employees' contracts. An empty array when the scope resolves to no department.
id*string · uuid
Unique identifier of the department.
example: 550e8400-e29b-41d4-a716-446655440001
name*string | null
Display name of the department.
example: Customer Support
employees*array<object>
Everyone the schedule may assign, resolved from the scope. This is the pool the slot assignment pickers and auto-assign draw from; booking anybody outside it is refused with a 422. The same list is available on its own from `GET /{pbx_id}/schedule-management/{schedule}/employees`.
Each item — One assignable person of a schedule: an employee the schedule's scope covers and
who may therefore be booked into its slots.
Only employees holding a contract that is active today are listed — someone who has
left, and someone whose contract has not started yet, is left out whatever the scope
type, including a hand-picked `employees` selection. The schedule's `scope` still
echoes the raw selection, so an edit form can round-trip what was picked.
The department is the one on the employee's most recent contract, supplied so a
picker can group or label its options when the schedule spans more than one
department. Both department fields are null for an employee whose contract carries
no department, which is normal for a company-scoped schedule.
id*string · uuid
Unique identifier of the employee.
example: 550e8400-e29b-41d4-a716-446655440010
fullName*string
Display name of the employee, ordered according to the tenant's first-name or last-name-first preference.
example: Jane Smith
departmentId*string | null · uuid
Identifier of the department on the employee's most recent contract. Null when that contract carries no department.
example: 550e8400-e29b-41d4-a716-446655440002
departmentName*string | null
Display name of the department on the employee's most recent contract. Null when that contract carries no department.
example: Customer Support
daysOfWeek*array<integer>
Weekdays covered by this schedule, stored as ISO 8601 weekday numbers
(1 = Monday through 7 = Sunday). Returned as an empty array when no days
are configured.
[]integer · int32
ISO 8601 weekday number (1 = Monday, 7 = Sunday).
enum: 1 2 3 4 5 6 7
example: 1
dayStartTime*string | null
Start of the daily working window in `HH:MM` 24-hour format (local
wall-clock, no timezone). Null when no start time is configured.
example: 09:00
dayEndTime*string | null
End of the daily working window in `HH:MM` 24-hour format (local
wall-clock, no timezone). Null when no end time is configured.
example: 17:30
slotDurationMinutes*integer · int32
Length in minutes of each bookable slot within the daily window. Defaults
to the configured Tempus slot duration (typically 30) when not set.
example: 30
statusobject | null
Default status assigned to entries generated from this schedule. Only
present when the `status` relation is eager-loaded; null when loaded but
no default status is set, and omitted entirely when the relation is not
loaded.
idstring · uuid
Unique identifier of the status.
example: 550e8400-e29b-41d4-a716-446655440002
namestring
Display name of the status.
example: Available
subStatusobject | null
Default sub-status assigned to entries generated from this schedule. Only
present when the `subStatus` relation is eager-loaded; null when loaded
but no default sub-status is set, and omitted entirely when the relation
is not loaded.
idstring · uuid
Unique identifier of the sub-status.
example: 550e8400-e29b-41d4-a716-446655440003
namestring
Display name of the sub-status.
example: On Break
statusFilters*array<string>
Identifiers of the statuses that are selectable on this schedule's grid.
Used to restrict which statuses planners may apply. Returned as an empty
array when no filter is configured (all statuses allowed).
[]string · uuid
Identifier of an allowed status.
example: 550e8400-e29b-41d4-a716-446655440002
isActive*boolean
Whether the schedule is active. Inactive schedules are retained but not
used to generate new planning entries.
example: 1
createdAt*string | null · date-time
ISO 8601 timestamp when the schedule was created.
read-only
example: 2024-03-01T08:29:07+00:00
updatedAt*string | null · date-time
ISO 8601 timestamp when the schedule was last updated.
read-only
example: 2024-03-01T08:29:07+00:00