Skip to main content

sdac-detect-vacant-positions

Purpose

Identifies vacant/open positions that still contain claimable salary or fringe costs.

Tool type

Deterministic (rule-based)

Tool ID

sdac-detect-vacant-positions

Inputs

  • report_id (string)
  • record_ids (number[], optional)

Outputs

  • errors and warnings for vacant positions with non-zero claimables

Example output

{
"success": true,
"report_id": "SDAC-2024-Q2-001",
"passed": false,
"error_count": 1,
"warning_count": 0,
"errors": [
{
"rule_id": "VACANT_POSITION_WITH_COSTS",
"row_number": 41,
"first_name": "Vacant",
"last_name": "",
"job_title": "Nurse",
"message": "Vacant position has claimable salary or fringe.",
"severity": "ERROR"
}
],
"warnings": []
}

Functional details

  • Detects vacancy via IsVacant flag or vacancy keywords in titles.
  • Flags any non-zero claimable salary/fringe on vacant rows.
  • Returns a summary list for reviewer follow-up.

Implementation details

  • Flags records where IsVacant is true or name/title contains vacant|open.
  • Emits VACANT_POSITION_NONZERO when claimable salary or fringe is > 0.
  • Successful checks add VACANT_POSITION_ZERO to executed rules.
  • Uses TotalClaimable when available to avoid double counting salary/fringe.

Code Location: packages/domain-sdac/src/tools/detect-vacant-positions.tool.ts