How to generate example request and response payloads?
dcs3spp opened this issue · comments
Hi,
Is there any example code for how to use go-oas to generate request and response examples for swagger docs?
Do schemas have to be manually specified or is there a way to generate them from golang structs?
Hi @dcs3spp ,
The current examples can be found (here)[https://github.com/go-oas/docs/tree/main/examples/file_output]. You might want to take a look at the combination of these two:
Schemas do not have to be manually specified. You have the freedom to either load via embedding or design one that might best fit your needs (as a wrapper around this library).
Also, you would be welcome to create an RFC or a PR to this codebase with what you would resolve your current needs - I am pretty open to any external input. 💪