Skip to content

Zod 4 supported #555

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
tangye1234 opened this issue May 27, 2025 · 0 comments
Open

Zod 4 supported #555

tangye1234 opened this issue May 27, 2025 · 0 comments
Labels
enhancement New feature or request

Comments

@tangye1234
Copy link

Is your feature request related to a problem? Please describe.
Currently, server.tool() uses a zod3 raw shape type for its input schema. Zod 4 is now currently release, and our input schema validation is all written in zod 4.

There isn't a compatible conversion between zod 3/4 up to now, so we are stuck here.

Describe the solution you'd like
I recommend to use a custom validation schema as an overload for this method, like vercel/ai-sdk.

Describe alternatives you've considered
We would also like to see the method supports v4/v3 both if the type can be inferred.

@tangye1234 tangye1234 added the enhancement New feature or request label May 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant