Closed thelinuxlich closed 6 months ago
Well, you cant really describe a stream object with json schema, so it would have to reflect the actual content. I take it the file contains binary and you dont want to deserialize it. You can represent the binary content as a base64 string and use z.string().base64(), which is now supported.
I'm not sure I understand your problem however. Can you provide some additional context?
@thelinuxlich Ok to close?
Yeah I think it's probably something on Fastify schema validation side
I see we have the file input case solved with latest Zod, but how can we have a ReadableStream output with a zod definition?