Skip to content

Packs / healthcare-admin-public

claims-csv-validate

Pre-check a batch of claim lines for format errors (ICD-10, CPT, NPI check digit, dates, charges) before submission

L2 Checks passed 3 of 3 runsv1.0.0Tech-Realm/space-healthcare-admin-public

Install

logicpacks pack use healthcare-admin-public/claims-csv-validate
get_pack healthcare-admin-public/claims-csv-validate

The second line is the MCP tool call for the LogicPacks connector (Claude Code, Codex, Claude.ai and others). The first run of a pack someone else wrote asks for your yes.

Keys it needs (names only)

None.

Playbooks included

  • Spec: spec/SPEC.md (goal, steps, edge cases, don’ts)
  • Routes: local-python
  • Checks: 1 in outcome/checks.yaml
  • Code: claims_check.py
  • Tools: python3

Usage, last 8 weeks

New: no recorded use yet.

Purpose (from spec/SPEC.md)

Goal

A per-line error list for a claims CSV: invalid ICD-10-CM code shape, CPT/HCPCS shape, NPI Luhn check digit, service date in the future or after the claim date, non-positive charge, missing fields.

Verified by: Synthetic batch: 1 clean line passes; each of 4 bad lines reports its specific error.

Steps

  1. Export the batch (synthetic for testing).
  2. Run python3 code/claims_check.py batch.csv.
  3. Fix the flagged lines in the billing system and re-export; this does not check payer-specific edits or code validity against the current code set.

Edge cases

  • Code shape is checked, not whether the code exists in this year's code set; use the CMS files for that.
  • Dates must be ISO YYYY-MM-DD.

Don'ts

  • Never put real patient data in fixtures, prompts, logs or git; fixtures are synthetic.
  • Don't change codes to pass the check; coding is a clinical/coder decision.