resourceObject
A resource performs work and can service stops based on skills, roster and location. Attribute names and types are links.
{
"id": <integer>,
"state": REST | WORK | BRK | STBY | CLLD,
"userId": <integer> | null,
"lock": <bool>,
}
-
idinteger - Unique identifier for this resource.
-
typeresourceParamsKey - References a previously defined resource type by key.
-
contractcontractParamsKey - References a previously defined contract by key.
-
stateREST | WORK | BRK | STBY | CLLD - Current operational state: REST (resting), WORK (working), BRK (on break), STBY (standby for callout), CLLD (called-out). CLLD marks "the resource has actually been called", and it is REQUIRED persistence: Spiral takes no action on it in normal running, but at startup re-seeds the CALL state onto the head STBY roster stop from it — an unmarked call would vanish across a Spiral restart. Helix acts as the host for these transitions, driving them ON TIME from the roster itself: the rest/standby status is the class of the ACTIVE roster entry, converged on every resource update and at each REST↔STBY boundary by a per-resource alarm on the event queue (only a resource already in REST or STBY is touched — WORK/BRK and the call states belong to other machinery). STBY→CLLD on receipt of the CALL (a host that stamps them first, as AA does, just gets there first), reverting to STBY if the call ends unanswered; accepting the callout rewrites the document to REST (roster + state together). The call itself always shows as CALL on the head STBY roster stop — its one valid home.
-
unprodstopObjectdefaultnull - Additional stops the resource must fulfil (usually directly; can be overridden).
-
atlocation - Current position in topography coordinates.
-
atTimetime - The time the current location (at) was last recorded.
-
baselocation - The resource’s normal home location.
-
roster[dutyKey: time] - Planned working roster — a duty key with a start time. Helix prunes EXPIRED rest/standby entries as it processes the resource (an entry ends when the next begins; the last never expires; work-classed history is never pruned), so the roster "shifts down" and the derived roster stops shift with it — no redundant stop emissions at period boundaries.
-
lastOfftime - Last end of active work; null if unknown.
-
lastOntime - Last start of active work; null if unknown.
-
lastBreaktime - Last completion of a break; null if unknown.
-
stopOntimeInterval - Maximum stop-on time that may be considered after the rostered finish; null is synonymous with 0.
-
userIdinteger - Deprecated — the Engineer sign-in binding now lives on the USER as `user.actsAs` (the set of resource ids a user may act as), configured in the Administration app. Retained for backward compatibility but no longer drives the Engineer view. If present, add it to the resource `ignore` list in the domain so Spiral never sees it.
-
currentWorkingLimitdistance - The resource’s current working-area distance limit (overrides the params soft / hard limits for now).
-
lockbooldefaultfalse - Prevents Spiral from rescheduling this resource.
-
skills[string: skillObject] - The resource’s base skills — a map of skill name → skillObject (not an array).