Improving Agama's OpenAPI specification
Hi all, As you may know, Agama can generate an OpenAPI specification for its HTTP API. Until recently, we had an "agama-web-server openapi" subcommand to do that. One advantage is that we could automatically generate clients/types from the spec. Sadly, the specification was invalid because **a lot** of stuff was missing. After some hours of Learning & Innovation, today I am merging a pull request that partially addresses those issues[1]. Kudos to Josef for the review. It implements the following changes: * It makes the OpenAPI specification valid. However, a few endpoints/types are still missing (DASD, issues, etc.). But at least what is included in the spec is valid. * The code that generates the specification is easier to work with. * The OpenAPI is generated at build time (as a xtask[2]) and included in a separate package (agama-openapi). Therefore the "openapi" subcommand is not available anymore. * The specification is generated and validated as part of our CI. So expect some red crosses from now on :-) Let's continue working toward a proper specification we can use to generate for our clients ;-) Regards, Imo [1] https://github.com/agama-project/agama/pull/1564 [2] https://github.com/agama-project/agama/pull/1650
participants (1)
-
Imobach Gonzalez Sosa