Accept the Official Hack: Build-Time OpenAPI Detection in .NET 10 Minimal APIs
It is straightforward to configure a minimal API to produce an OpenAPI document at build time. This runs the API during build, requests the OpenAPI document from it, and saves it to disk.
The slightly
naveedausaf.com7 min read