Skip to content

chore: complete Zod v4 migration in SDK#63

Merged
vreshch merged 1 commit intomasterfrom
chore/zod-v4
Mar 4, 2026
Merged

chore: complete Zod v4 migration in SDK#63
vreshch merged 1 commit intomasterfrom
chore/zod-v4

Conversation

@vreshch
Copy link
Contributor

@vreshch vreshch commented Mar 4, 2026

Summary

  • Use native toJSONSchema() from zod package instead of instance method
  • Detect Zod v4 schemas via _zod property (with _def fallback for compatibility)
  • Fix optional field detection to use _zod.def.type instead of _def.typeName
  • Use caret range (^4.3.6) for zod dependency

Test plan

  • All 26 SDK tests pass
  • Type-check passes
  • CI passes

- Use native toJSONSchema() from zod instead of removed .toJSONSchema() method
- Detect Zod schemas via _zod property (v4) with _def fallback
- Check optional type via _zod.def.type instead of _def.typeName
- Use caret range for zod dependency
@github-actions
Copy link

github-actions bot commented Mar 4, 2026

🔍 Pull Request Validation Results

Step Status
🔍 Type Check ✅ Passed
🎨 Lint ✅ Passed
🏗️ Build ✅ Passed
🧪 Tests ✅ Passed
📊 Coverage ✅ Passed
📦 Examples ✅ Passed

Overall: ✅ All checks passed!

📋 View workflow


⏰ Generated at: 2026-03-04T23:34:21.179Z

@vreshch vreshch merged commit 09bfcd3 into master Mar 4, 2026
3 checks passed
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.

1 participant