export {
  createDemandRequirement,
  type DemandRequirementWithRelations,
} from "./use-cases/allocation/create-demand-requirement.js";
export { updateDemandRequirement } from "./use-cases/allocation/update-demand-requirement.js";

export {
  createAssignment,
  type AssignmentWithRelations,
} from "./use-cases/allocation/create-assignment.js";
export { updateAssignment } from "./use-cases/allocation/update-assignment.js";

export { buildAllocationReadModel } from "./use-cases/allocation/build-allocation-read-model.js";
export {
  buildSplitAllocationReadModel,
  type BuildSplitAllocationReadModelInput,
  type SplitAssignmentRecord,
  type SplitDemandRequirementRecord,
} from "./use-cases/allocation/build-split-allocation-read-model.js";
export {
  listAssignmentBookings,
  type AssignmentBookingWithFallback,
  type ListAssignmentBookingsInput,
} from "./use-cases/allocation/list-assignment-bookings.js";
export {
  isChargeabilityActualBooking,
  isChargeabilityRelevantProject,
  isImportedTbdDraftProject,
} from "./use-cases/allocation/chargeability-bookings.js";
export {
  countPlanningEntries,
  type CountPlanningEntriesInput,
  type CountPlanningEntriesResult,
} from "./use-cases/allocation/count-planning-entries.js";
export {
  countEstimateHandoffPlanningEntries,
  type CountEstimateHandoffPlanningEntriesInput,
} from "./use-cases/allocation/count-estimate-handoff-planning-entries.js";

export {
  fillDemandRequirement,
  type FillDemandRequirementResult,
} from "./use-cases/allocation/fill-demand-requirement.js";

export {
  fillOpenDemand,
  type FillOpenDemandResult,
} from "./use-cases/allocation/fill-open-demand.js";

export {
  findAllocationEntry,
  loadAllocationEntry,
  type AllocationEntryResolution,
} from "./use-cases/allocation/load-allocation-entry.js";
export {
  updateAllocationEntry,
  type UpdateAllocationEntryInput,
  type UpdateAllocationEntryResult,
} from "./use-cases/allocation/update-allocation-entry.js";
export {
  deleteAllocationEntry,
  type DeleteAllocationEntryResult,
} from "./use-cases/allocation/delete-allocation-entry.js";
export {
  deleteDemandRequirement,
  type DeleteDemandRequirementResult,
} from "./use-cases/allocation/delete-demand-requirement.js";
export {
  deleteAssignment,
  type DeleteAssignmentResult,
} from "./use-cases/allocation/delete-assignment.js";

export {
  getDashboardOverview,
  getDashboardPeakTimes,
  getDashboardTopValueResources,
  getDashboardDemand,
  getDashboardChargeabilityOverview,
  type GetDashboardPeakTimesInput,
  type GetDashboardTopValueResourcesInput,
  type GetDashboardDemandInput,
  type GetDashboardChargeabilityOverviewInput,
  type DashboardChargeabilityDerivation,
  type DashboardChargeabilityRow,
  getDashboardBudgetForecast,
  type BudgetForecastDerivationSummary,
  type BudgetForecastRow,
  type BudgetForecastLocationSummary,
  type PeakTimesPeriodDerivation,
  type PeakTimesPeriodRow,
  type DemandCalendarLocationSummary,
  type DemandRowDerivation,
  type DashboardDemandRow,
  getDashboardSkillGaps,
  getDashboardSkillGapSummary,
  type SkillGapRow,
  type DashboardSkillGapSummary,
  getDashboardProjectHealth,
  type ProjectHealthRow,
} from "./use-cases/dashboard/index.js";

export {
  cloneEstimate,
  createEstimate,
  listEstimates,
  getEstimateById,
  updateEstimateDraft,
  submitEstimateVersion,
  approveEstimateVersion,
  createEstimateRevision,
  createEstimateExport,
  createEstimatePlanningHandoff,
  type CloneEstimateInput,
  type EstimateWithDetails,
  type EstimateListItem,
} from "./use-cases/estimate/index.js";

export {
  recomputeResourceValueScores,
  type RecomputeResourceValueScoresInput,
} from "./use-cases/resource/index.js";

export {
  calculateEffectiveAllocationCostCents,
  calculateEffectiveAllocationHours,
  calculateEffectiveAvailableHours,
  calculateEffectiveBookedHours,
  calculateEffectiveDayAvailability,
  countEffectiveWorkingDays,
  enumerateIsoDates,
  getAvailabilityHoursForDate,
  loadResourceDailyAvailabilityContexts,
  type ResourceCapacityProfile,
  type ResourceDailyAvailabilityContext,
} from "./lib/resource-capacity.js";

export {
  assessDispoImportReadiness,
  parseMandatoryDispoReferenceWorkbook,
  parseDispoChargeabilityWorkbook,
  parseDispoPlanningWorkbook,
  parseResourceRosterMasterWorkbook,
  parseDispoRosterWorkbook,
  persistDispoImportReadiness,
  stageDispoReferenceData,
  stageDispoChargeabilityResources,
  stageDispoRosterResources,
  stageDispoPlanningData,
  stageDispoProjects,
  stageDispoImportBatch,
  commitDispoImportBatch,
  type AssessDispoImportReadinessInput,
  type CommitDispoImportBatchInput,
  type CommitDispoImportBatchResult,
  type DispoImportReadinessIssue,
  type DispoImportReadinessReport,
  type StageDispoReferenceDataResult,
  type StageDispoChargeabilityResourcesResult,
  type StageDispoRosterResourcesResult,
  type StageDispoPlanningResult,
  type StageDispoProjectsResult,
  type StageDispoImportBatchInput,
  type StageDispoImportBatchResult,
} from "./use-cases/dispo-import/index.js";
