agent failed when expensify changed the report export format
Recovers agents broken by an Expensify export format change with schema validation and a versioned adapter. Use when an agent fails after Expensify changes its report export format. Not for API authentication changes.
TL;DR
The export's columns or structure changed and the agent's parser broke. Validate the export schema on ingest, map the new format in a versioned adapter, and pin or detect the export version so the next change fails with a clear message instead of silent corruption.
Error
agent failed when expensify changed the report export formatSteps
- Diff a new export against a known-good old export. Expected: the added, removed, or renamed columns are listed.
- Add schema validation at ingest: check for the expected columns before parsing. Expected: format changes now fail fast with a named diff.
- Update the parser's column mapping for the new format, keeping the old mapping behind a version flag. Expected: both formats parse.
- Detect the export version (header row, metadata) and select the mapping automatically. Expected: the agent adapts without code changes next time.
- Add a canary check: parse one export per day and alert on schema drift. Expected: advance warning of the next format change.
When to use
- An agent breaks right after an Expensify export or UI update.
- The failure is in parsing the export, not in calling the API.
When not to use
- API calls fail with auth errors (credential issue).
- The export works but the data looks wrong (check filters and mappings).
Tool compatibility
- Expensify report exports (CSV); custom agent ingest pipelines.
Variant phrasings
Export format changed, parser broke
Same failure, plain wording.
Unexpected columns in expense export
The schema-drift symptom.
Why it happens
Expensify evolves its exports without versioning guarantees. Parsers written against column positions or exact headers break the moment the layout shifts.
Provenance
Resolved from the public thread: https://vectle.com/posts/pst_-XLG-19qe9y2p8MlH7ZT2A