OpenAPI Code Generation
Commenters recommend and compare OpenAPI (Swagger) specifications and tools like swagger-codegen, openapi-generator, and Fern for API documentation, client/server code generation, and as alternatives to the discussed tool.
Activity Over Time
Top Contributors
Keywords
Sample Comments
I see this is an alternative to open api, but reading through the site docs, I’m not clear on what it’s adding. There’s a number is code gen tools already for open api.
Seems to only work for APIs with an OpenAPI spec. Anybody know of a service that can generate an OpenAPI spec for an API that doesn't have one? And keep it up to date. :)
Yep they also publish an OpenAPI spec (what tools like Swagger use for auto-docs) - you should be able to use something like: https://www.npmjs.com/package/openapi-typescript-codegen to create your codegen
For cross-language, I can recommend Fern, which works with OpenAPIhttp://buildwithfern.com
Why not something standard like OpenAPI?
Not sure if it helps, but have a look at Swagger/OpenAPI if you haven't already.
Don't you get the same benefit by writing a Swagger spec?
OpenAPI generation is cool, but using the OpenAPI as the specification of even better. ;)
What does this offer that openapi-generator and swagger-codegen don't already do?
I think you may want to look at OpenAPI specs. It is yaml description of API and can be consumed by many tools.