Monument

Schedule

Schedule data, milestones, actuals, dependencies, and timeline operations.

externalpermissionstable29 procedures
queryschedule.getDataInferred output

Get all schedule data. Returns root tasks (projects), child tasks, resources, resource pools, and allocations. Business logic is in domain/services/schedule.service.ts

Input
{
  rootTaskId?: string | undefined;
  versionId?: string | undefined;
  startDate?: string | undefined;
  endDate?: string | undefined;
  allocationLimit?: number | undefined;
} | undefined
Output
ScheduleData
queryschedule.getReferenceDataInferred output

No description provided.

Input
unknown
Output
ScheduleReferenceData
queryschedule.getProjectPageInferred output

No description provided.

Input
{
  status?: Array<string> | undefined;
  versionId?: string | undefined;
  mode?: "all" | "archive" | "live" | undefined;
  search?: string | undefined;
  limit?: number | undefined;
  cursor?: string | undefined;
  dateQuality?: Array<"source" | "fallback" | "mixed" | "unknown"> | undefined;
} | undefined
Output
ScheduleProjectPage
queryschedule.getTaskTreeInferred output

No description provided.

Input
{
  rootTaskIds: Array<string>;
  versionId?: string | undefined;
  maxDepth?: number | undefined;
  includeCollapsedChildren?: boolean | undefined;
}
Output
ScheduleTaskTreeData
queryschedule.getWindowDataInferred output

No description provided.

Input
{
  dateFrom: string;
  dateTo: string;
  rootTaskIds: Array<string>;
  versionId?: string | undefined;
  resourceIds?: Array<string> | undefined;
  allocationLimit?: number | undefined;
  include?: Array<"milestones" | "leave" | "allocations" | "taskBudgets" | "dependencies" | "taskActuals" | "resourceActuals" | "resourceTaskActuals" | "resourceTaskActualSeries" | "financialEvents" | "invoiceFlags"> | undefined;
  actualsGranularity?: "day" | "week" | "month" | undefined;
  resourcePoolIds?: Array<string> | undefined;
}
Output
ScheduleWindowData
queryschedule.getFinancialDataInferred output

Get financial data for the schedule chart. Returns milestone revenue, staff costs, and operational expenses. Business logic is in domain/services/schedule.service.ts

Input
{
  rootTaskId?: string | undefined;
  dateFrom?: string | undefined;
  dateTo?: string | undefined;
  rootTaskIds?: Array<string> | undefined;
} | undefined
Output
FinancialData
queryschedule.getFinancialSeriesInferred output

No description provided.

Input
{
  dateFrom: string;
  dateTo: string;
  rootTaskIds: Array<string>;
  granularity: "week" | "month";
  revenueTarget?: number | null | undefined;
}
Output
ScheduleFinancialSeriesResponse
queryschedule.getMilestoneFinancialInputsInferred output

No description provided.

Input
{
  rootTaskIds: Array<string>;
  taskIds?: Array<string> | undefined;
}
Output
ScheduleMilestoneFinancialInputsResponse
queryschedule.getFinancialPeriodDetailsInferred output

No description provided.

Input
{
  rootTaskIds: Array<string>;
  periodStart: string;
  periodEnd: string;
}
Output
FinancialPeriodDetails
queryschedule.resolveResourceRateInferred output

Resolve the effective rates for a resource. Used by allocation editing flows to compare planned rate vs resource default rate.

Input
{
  resourceId: string;
}
Output
EffectiveRatesInfo
mutationschedule.updateAllocationInferred output

Update an allocation's hours or other properties.

Input
{
  id: string;
  resourceId?: string | null | undefined;
  taskId?: string | undefined;
  assignmentType?: "unassigned" | "resource" | "resource_pool" | undefined;
  resourcePoolId?: string | null | undefined;
  slotId?: string | null | undefined;
  trackId?: string | null | undefined;
  startDate?: string | undefined;
  endDate?: string | undefined;
  segments?: Array<{
    start: string;
    end: string;
  }> | undefined;
  formula?: string | undefined;
  calculationType?: "fixed" | "fixed_periodic" | "formula" | undefined;
  hours?: number | undefined;
  hoursPerDay?: number | undefined;
  frequency?: "one_time" | "daily" | "weekly" | "fortnightly" | "monthly" | "quarterly" | "yearly" | undefined;
  percentage?: number | undefined;
  modifiers?: Array<{
    id: string;
    value: string;
    type: "percentage" | "amount";
    name: string;
  }> | null | undefined;
  dependentAllocationIds?: Array<string> | undefined;
  calculatedHours?: number | undefined;
  billingRateId?: string | null | undefined;
  billingRateVersionId?: string | null | undefined;
  contingencyPercentage?: number | undefined;
}
Output
{
  id: string;
  resourceId: string | null;
  organizationId: string;
  taskId: string;
  rootTaskId: string | null;
  versionId: string;
  taskHoursId: string | null;
  name: string | null;
  assignmentType: "unassigned" | "resource" | "resource_pool";
  resourcePoolId: string | null;
  slotId: string | null;
  createdAt: Date;
  updatedAt: Date | null;
  deletedAt: Date | null;
  trackId: string | null;
  startDate: string;
  endDate: string;
  segments: Array<{
    start: string;
    end: string;
  }> | null;
  formula: string | null;
  calculationType: "fixed" | "fixed_periodic" | "from_expenses" | "from_hours" | "from_allocations" | "sum_of_children_auto" | "formula";
  hours: string | null;
  hoursPerDay: string | null;
  frequency: "one_time" | "daily" | "weekly" | "fortnightly" | "monthly" | "quarterly" | "yearly" | null;
  percentage: string | null;
  basePercentage: string | null;
  rateId: string | null;
  modifiers: unknown;
  dependentTaskIds: Array<string> | null;
  dependentAllocationIds: Array<string> | null;
  calculatedHours: string | null;
  billingRateId: string | null;
  costRateId: string | null;
  billingRateVersionId: string | null;
  costRateVersionId: string | null;
  projectBillingRateId: string | null;
  projectCostRateId: string | null;
  locked: boolean | null;
  visible: boolean | null;
  notes: string | null;
  progressPercent: string | null;
  startedAt: Date | null;
  completedAt: Date | null;
} | null
mutationschedule.insertDelayInferred output

Insert a calendar-day delay into a task and cascade it through descendants and their allocations in a single transaction.

Input
{
  taskId: string;
  gapStart: string;
  gapEnd: string;
}
Output
InsertDelayCascadeResult
mutationschedule.splitAllocationInferred output

Split an allocation into two parts at a specific date. This is used when editing a week/day that differs from the rest of the allocation. The original allocation is kept for one segment, and a new allocation is created for the other. The segment receiving updates gets the new allocation ID.

Input
{
  allocationId: string;
  splitDate: string;
  splitType: "at" | "before" | "after";
  splitEndDate?: string | undefined;
  segmentUpdates?: {
    resourceId?: string | null | undefined;
    resourcePoolId?: string | null | undefined;
    startDate?: string | undefined;
    endDate?: string | undefined;
    hours?: number | undefined;
    hoursPerDay?: number | undefined;
  } | undefined;
}
Output
SplitResult | null
mutationschedule.deleteAllocationInferred output

Delete an allocation (soft delete).

Input
{
  id: string;
}
Output
{
  id: string;
  resourceId: string | null;
  organizationId: string;
  taskId: string;
  rootTaskId: string | null;
  versionId: string;
  taskHoursId: string | null;
  name: string | null;
  assignmentType: "unassigned" | "resource" | "resource_pool";
  resourcePoolId: string | null;
  slotId: string | null;
  createdAt: Date;
  updatedAt: Date | null;
  deletedAt: Date | null;
  trackId: string | null;
  startDate: string;
  endDate: string;
  segments: Array<{
    start: string;
    end: string;
  }> | null;
  formula: string | null;
  calculationType: "fixed" | "fixed_periodic" | "from_expenses" | "from_hours" | "from_allocations" | "sum_of_children_auto" | "formula";
  hours: string | null;
  hoursPerDay: string | null;
  frequency: "one_time" | "daily" | "weekly" | "fortnightly" | "monthly" | "quarterly" | "yearly" | null;
  percentage: string | null;
  basePercentage: string | null;
  rateId: string | null;
  modifiers: unknown;
  dependentTaskIds: Array<string> | null;
  dependentAllocationIds: Array<string> | null;
  calculatedHours: string | null;
  billingRateId: string | null;
  costRateId: string | null;
  billingRateVersionId: string | null;
  costRateVersionId: string | null;
  projectBillingRateId: string | null;
  projectCostRateId: string | null;
  locked: boolean | null;
  visible: boolean | null;
  notes: string | null;
  progressPercent: string | null;
  startedAt: Date | null;
  completedAt: Date | null;
} | null
mutationschedule.createAllocationInferred output

Create a new resource allocation.

Input
{
  taskId: string;
  startDate: string;
  endDate: string;
  id?: string | undefined;
  resourceId?: string | null | undefined;
  name?: string | undefined;
  assignmentType?: "unassigned" | "resource" | "resource_pool" | undefined;
  resourcePoolId?: string | null | undefined;
  slotId?: string | null | undefined;
  trackId?: string | null | undefined;
  segments?: Array<{
    start: string;
    end: string;
  }> | undefined;
  formula?: string | undefined;
  calculationType?: "fixed" | "fixed_periodic" | "formula" | undefined;
  hours?: number | undefined;
  hoursPerDay?: number | undefined;
  frequency?: "one_time" | "daily" | "weekly" | "fortnightly" | "monthly" | "quarterly" | "yearly" | undefined;
  percentage?: number | undefined;
  dependentAllocationIds?: Array<string> | undefined;
  calculatedHours?: number | undefined;
  contingencyPercentage?: number | undefined;
}
Output
{
  id: string;
  resourceId: string | null;
  organizationId: string;
  taskId: string;
  rootTaskId: string | null;
  versionId: string;
  taskHoursId: string | null;
  name: string | null;
  assignmentType: "unassigned" | "resource" | "resource_pool";
  resourcePoolId: string | null;
  slotId: string | null;
  createdAt: Date;
  updatedAt: Date | null;
  deletedAt: Date | null;
  trackId: string | null;
  startDate: string;
  endDate: string;
  segments: Array<{
    start: string;
    end: string;
  }> | null;
  formula: string | null;
  calculationType: "fixed" | "fixed_periodic" | "from_expenses" | "from_hours" | "from_allocations" | "sum_of_children_auto" | "formula";
  hours: string | null;
  hoursPerDay: string | null;
  frequency: "one_time" | "daily" | "weekly" | "fortnightly" | "monthly" | "quarterly" | "yearly" | null;
  percentage: string | null;
  basePercentage: string | null;
  rateId: string | null;
  modifiers: unknown;
  dependentTaskIds: Array<string> | null;
  dependentAllocationIds: Array<string> | null;
  calculatedHours: string | null;
  billingRateId: string | null;
  costRateId: string | null;
  billingRateVersionId: string | null;
  costRateVersionId: string | null;
  projectBillingRateId: string | null;
  projectCostRateId: string | null;
  locked: boolean | null;
  visible: boolean | null;
  notes: string | null;
  progressPercent: string | null;
  startedAt: Date | null;
  completedAt: Date | null;
}
queryschedule.getResourceActualsDataInferred output

Get resource-level actuals data (time entries aggregated by resource and date). Used for hour labels on resource swimlanes.

Input
{
  dateFrom?: string | undefined;
  dateTo?: string | undefined;
} | undefined
Output
Array<ResourceDayActual>
queryschedule.getResourceTaskActualsDataInferred output

Get resource+task-level actuals data (time entries aggregated by resource, task, and date). Used for split-by-project parity and synthetic actuals-only bars in resource swimlanes.

Input
{
  dateFrom?: string | undefined;
  dateTo?: string | undefined;
} | undefined
Output
Array<ResourceTaskDayActual>
queryschedule.getActualsDataInferred output

Get actuals data for the schedule. Returns time entries aggregated by task and blended progress calculations. Progress calculation uses a "blended" approach: - Days with recorded time: Use actual time entries - Days without recorded time (in the past): Use allocated hours - Future days: Always use allocations

Input
{
  dateFrom?: string | undefined;
  dateTo?: string | undefined;
  taskIds?: Array<string> | undefined;
} | undefined
Output
ActualsData
queryschedule.getDependenciesInferred output

Get all dependencies for the organization.

Input
unknown
Output
Array<{
  id: string;
  fromTaskId: string;
  toTaskId: string;
  dependencyType: "FS" | "SS" | "FF" | "SF";
  lagDays: number;
  notes: string | null;
}>
mutationschedule.createDependencyInferred output

Create a new task dependency.

Input
{
  fromTaskId: string;
  toTaskId: string;
  notes?: string | undefined;
  dependencyType?: "FS" | "SS" | "FF" | "SF" | undefined;
  lagDays?: number | undefined;
}
Output
{
  id: string;
  organizationId: string;
  createdAt: Date;
  updatedAt: Date | null;
  deletedAt: Date | null;
  notes: string | null;
  fromTaskId: string;
  toTaskId: string;
  dependencyType: "FS" | "SS" | "FF" | "SF";
  lagDays: number;
}
mutationschedule.updateDependencyInferred output

Update a task dependency.

Input
{
  id: string;
  notes?: string | null | undefined;
  dependencyType?: "FS" | "SS" | "FF" | "SF" | undefined;
  lagDays?: number | undefined;
}
Output
{
  id: string;
  organizationId: string;
  createdAt: Date;
  updatedAt: Date | null;
  deletedAt: Date | null;
  notes: string | null;
  fromTaskId: string;
  toTaskId: string;
  dependencyType: "FS" | "SS" | "FF" | "SF";
  lagDays: number;
} | null
mutationschedule.deleteDependencyInferred output

Delete a task dependency (soft delete).

Input
{
  id: string;
}
Output
{
  id: string;
  organizationId: string;
  createdAt: Date;
  updatedAt: Date | null;
  deletedAt: Date | null;
  notes: string | null;
  fromTaskId: string;
  toTaskId: string;
  dependencyType: "FS" | "SS" | "FF" | "SF";
  lagDays: number;
} | null
mutationschedule.flipDependencyInferred output

Flip a dependency direction (swap from/to tasks).

Input
{
  id: string;
}
Output
{
  id: string;
  organizationId: string;
  createdAt: Date;
  updatedAt: Date | null;
  deletedAt: Date | null;
  notes: string | null;
  fromTaskId: string;
  toTaskId: string;
  dependencyType: "FS" | "SS" | "FF" | "SF";
  lagDays: number;
} | null
mutationschedule.createMilestoneInferred output

Create a new milestone. Note: Milestones require a project (rootTaskId) - they cannot exist without one.

Input
{
  rootTaskId: string;
  name: string;
  targetDate: string;
  id?: string | undefined;
  completionCriteria?: Array<{
    taskId: string;
    targetProgress: number;
    mustComplete?: boolean | undefined;
    subCriteria?: Array<{
      percentage: number;
      itemType: "hours" | "revenue" | "expense";
      itemId: string;
      itemName: string;
    }> | undefined;
  }> | undefined;
  triggersInvoice?: boolean | undefined;
}
Output
{
  id: string;
  status: "upcoming" | "at_risk" | "completed" | "missed" | null;
  organizationId: string;
  rootTaskId: string;
  versionId: string;
  name: string;
  createdAt: Date;
  updatedAt: Date | null;
  deletedAt: Date | null;
  description: string | null;
  targetDate: string;
  completedDate: string | null;
  completionCriteria: Array<{
    taskId: string;
    targetProgress: number;
    mustComplete: boolean;
    subCriteria?: Array<{
      itemType: "hours" | "revenue" | "expense";
      itemId: string;
      itemName: string;
      percentage: number;
    }> | undefined;
  }> | null;
  triggersInvoice: boolean | null;
  invoicePercentage: string | null;
  invoiceAmount: string | null;
}
mutationschedule.updateMilestoneInferred output

Update an existing milestone.

Input
{
  id: string;
  rootTaskId?: string | undefined;
  name?: string | undefined;
  targetDate?: string | undefined;
  completionCriteria?: Array<{
    taskId: string;
    targetProgress: number;
    mustComplete?: boolean | undefined;
    subCriteria?: Array<{
      percentage: number;
      itemType: "hours" | "revenue" | "expense";
      itemId: string;
      itemName: string;
    }> | undefined;
  }> | undefined;
  triggersInvoice?: boolean | undefined;
}
Output
{
  id: string;
  status: "upcoming" | "at_risk" | "completed" | "missed" | null;
  organizationId: string;
  rootTaskId: string;
  versionId: string;
  name: string;
  createdAt: Date;
  updatedAt: Date | null;
  deletedAt: Date | null;
  description: string | null;
  targetDate: string;
  completedDate: string | null;
  completionCriteria: Array<{
    taskId: string;
    targetProgress: number;
    mustComplete: boolean;
    subCriteria?: Array<{
      itemType: "hours" | "revenue" | "expense";
      itemId: string;
      itemName: string;
      percentage: number;
    }> | undefined;
  }> | null;
  triggersInvoice: boolean | null;
  invoicePercentage: string | null;
  invoiceAmount: string | null;
}
mutationschedule.deleteMilestoneInferred output

Delete a milestone (soft delete).

Input
{
  id: string;
}
Output
{
  id: string;
}
queryschedule.previewBillingMilestonesInferred output

Preview billing milestones that would be generated. Returns milestone data without creating anything in the database.

Input
{
  rootTaskId: string;
  cadenceConfig: {
    type: "day_of_month";
    day: number;
  } | {
    type: "nth_weekday";
    nth: "first" | "last" | "second" | "third" | "fourth";
    weekday: 0 | 1 | 2 | 3 | 5 | 4 | 6;
  } | {
    type: "weekly";
    weekday: 0 | 1 | 2 | 3 | 5 | 4 | 6;
  } | {
    type: "on_task_completion";
  };
  progressMethod?: "allocation" | "linear" | undefined;
}
Output
Array<GeneratedMilestone>
mutationschedule.generateBillingMilestonesInferred output

Generate billing milestones for a project. Creates milestones based on the selected cadence. Draft invoices are auto-created by milestone service via triggersInvoice flag.

Input
{
  rootTaskId: string;
  cadenceConfig: {
    type: "day_of_month";
    day: number;
  } | {
    type: "nth_weekday";
    nth: "first" | "last" | "second" | "third" | "fourth";
    weekday: 0 | 1 | 2 | 3 | 5 | 4 | 6;
  } | {
    type: "weekly";
    weekday: 0 | 1 | 2 | 3 | 5 | 4 | 6;
  } | {
    type: "on_task_completion";
  };
  progressMethod?: "allocation" | "linear" | undefined;
}
Output
GenerateBillingMilestonesResult
mutationschedule.recalculateMilestoneInvoiceInferred output

Recalculate a milestone's draft invoice with current data. Uses actuals if the milestone date has passed, otherwise re-estimates.

Input
{
  milestoneId: string;
}
Output
{
  invoiceId: string;
}