Skip to content

fix(zod): support zod v4 mini schemas#1985

Open
morgan-coded wants to merge 1 commit into
openai:mainfrom
morgan-coded:fix/1564-zod-v4-mini
Open

fix(zod): support zod v4 mini schemas#1985
morgan-coded wants to merge 1 commit into
openai:mainfrom
morgan-coded:fix/1564-zod-v4-mini

Conversation

@morgan-coded

Copy link
Copy Markdown
  • I understand that this repository is auto-generated and my pull request may not be merged

Changes being requested

zod/v4-mini schemas did not type-check with the structured-output helpers because they only accepted Zod v3 and regular Zod v4 schema types. This widens those helpers to accept mini schemas, keeps the existing v3/v4 JSON Schema conversion paths, and uses one parser path for response, text, and tool arguments. I checked the new mini coverage failing under TypeScript before the helper change, then ran ./scripts/bootstrap, ./scripts/test tests/helpers/zod.test.ts, ./node_modules/typescript/bin/tsc, pnpm build, pnpm lint, and pnpm test with 1145 passing and 1 skipped. Fixes #1564

Additional context & links

@morgan-coded morgan-coded requested a review from a team as a code owner July 7, 2026 02:58
Copilot AI review requested due to automatic review settings July 7, 2026 02:58

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support for zod/v4-mini

2 participants