Skip to content

v0.4.6: Zod regex + workflow hints on ID fields

Choose a tag to compare

@cyanheads cyanheads released this 26 May 19:51
v0.4.6
c8cd7f7

Zod regex + workflow hints on ID fields

Adds structural schema validation and discovery hints to candidate_id
and committee_id parameters across all tool definitions.

Changed:

  • candidate_id fields — added .regex(/^[HSP][0-9A-Z]+$/i) to surface a pattern in JSON Schema; updated .describe() to point callers to openfec_search_candidates for IDs (#2)
  • committee_id fields — added .regex(/^C\d+$/i) to surface a pattern in JSON Schema; updated .describe() to point callers to openfec_search_committees for IDs (#2)
  • Tests — updated invalid-ID assertions to expect ZodError at parse time

129 tests pass; bun run devcheck clean (outdated-dep advisory pre-existing, unrelated).