Matter File Check
Which matter files are missing something, and who owes it.
What it does
Reads your MatterFile sheet — one row per document a matter file is supposed to hold — and checks the matching folder:
<MATTER_FILE_ROOT>/<matter>/<expected_filename>
Then reports incomplete matters, naming each missing document and its owner, and lists the matters where every expected file is present.
What it does NOT do
It does not open a single file. This is a presence-and-naming check. "Present" means a file with that name exists in that folder — not that it is signed, not that it is dated, not that it is the right version, not that anyone read it.
It is not a compliance attestation. A matter appearing in the complete list means the filenames are there and nothing more. Anyone treating this output as evidence that a file is in order for a bar audit, a client audit, or an insurer has misread it — and the digest says so, in the header, every time.
It does not assemble documents. It will not generate an engagement letter, fill a template, or apply your letterhead. Nothing in the Hub does that today, and a workflow implying otherwise would disappoint on first run.
Setup
1. Google Sheet
Tab MatterFile with this header:
| matter | client | document | expected_filename | owner | status |
|---|---|---|---|---|---|
One row per document the file should hold. A typical set:
- Engagement letter
- Signed retainer
- Conflict-check record
- Client ID verification
- Fee agreement
Rules:
- matter must match the folder name on disk exactly
- status = done, skip or waived drops a row without deleting it — use waived when a document genuinely does not apply to that matter, so the exception is recorded rather than silently absent
2. Folder layout
Create <<MATTER_FILE_ROOT>> with one folder per matter, readable by the InTouch server. Nothing is written; read access is enough.
3. Credential + contact
<<GOOGLE_WORKSPACE_CREDENTIAL>>— Google Workspace credential with Sheets read scope<<MATTER_FILE_SHEET_ID>>— the sheet ID from its URL<<MATTER_FILE_ROOT>>— the folder root<<PRACTICE_MANAGER_PUBLISHER>>— who receives the digest
4. Schedule
Weekly. Daily during a period of heavy file-opening.
Customization
- Zero-byte files. A failed export is a file that exists and is empty. Add
os.path.getsize(target) > 0besideos.path.isfileincompose. - Per-owner lists. Group by column E and run once per owner, the way
deliverable-pack-checkdoes, so each person gets only their own. - New matters only. Add a date column and filter in
composeif checking every matter every week is noisy.
Source
workflow.iml