HN user

wing328hk

94 karma

Core team and founding member of OpenAPI Generator, which is a free, open-source project to automatically generate API clients, server stubs, schemas, API documentation and more based on OpenAPI/Swagger specifications: https://github.com/OpenAPITools/openapi-generator

Posts65
Comments60
View on HN
news.ycombinator.com 3y ago

Show HN: Auto-Generate Python REST API Clients Using OpenAPI Generator

wing328hk
5pts2
twitter.com 5y ago

OpenAPI Generator v5.1.1 released with a new go-echo-server generator

wing328hk
2pts0
news.ycombinator.com 5y ago

Show HN: Go Echo Server Generator

wing328hk
1pts0
forum.crystal-lang.org 5y ago

Cyrstal API Client Generator

wing328hk
1pts0
github.com 5y ago

OpenAPI Generator v5.0.0-beta3 released with Angular 11 support and more

wing328hk
2pts0
twitter.com 5y ago

OpenAPI Generator CLI v2 released with a new version manager

wing328hk
1pts0
github.com 5y ago

OpenAPI Generator v5.0.0-beta2 released with Angular10, RxJava3 support and more

wing328hk
1pts0
twitter.com 6y ago

OpenAPI Generator 5.0.0-beta released with 3 new generators

wing328hk
1pts0
twitter.com 6y ago

OpenAPI Generator v4.3.1 released with 4 new generators/libraries

wing328hk
1pts0
news.ycombinator.com 6y ago

Show HN: Auto-generate ASP.NET Core servers stub for REST APIs

wing328hk
1pts0
github.com 6y ago

OpenAPI Generator v4.3.0 released with 3 new generators

wing328hk
2pts0
www.reddit.com 6y ago

Using OpenAPI Generator to Generate PowerShell API Clients

wing328hk
2pts0
news.ycombinator.com 6y ago

Show HN: Auto-Generate Scala API Clients for REST APIs

wing328hk
4pts0
www.reddit.com 6y ago

OpenAPI Generator now supports Angular 9

wing328hk
2pts0
github.com 6y ago

OpenAPI Generator v4.2.3 released with 2 new generators: swift5, markdown

wing328hk
1pts0
www.reddit.com 6y ago

Auto-Generate Swift 5 API Client for REST APIs

wing328hk
2pts0
github.com 6y ago

OpenAPI Generator 4.2.2 (2019 last release): new TS redux-query generator

wing328hk
6pts5
github.com 6y ago

OpenAPI Generator v4.2.1 Released

wing328hk
2pts0
github.com 6y ago

Auto-generated PHP Slim 4 server stub using OpenAPI Generator

wing328hk
2pts0
news.ycombinator.com 6y ago

Show HN: Auto-Generate Java Vert.x Web Server Stub Using OpenAPI Generator

wing328hk
3pts0
twitter.com 6y ago

The 50th release of OpenAPI Generator: v4.2.0 with 3 new generators

wing328hk
1pts0
twitter.com 6y ago

OpenAPI Generator v4.1.3 release comes with 4 new generators

wing328hk
2pts0
news.ycombinator.com 6y ago

OpenAPI Generator's Kotlin client generator now supports multiplatform

wing328hk
1pts0
news.ycombinator.com 6y ago

Show HN: F# Server stub generator for Azure functions

wing328hk
2pts0
news.ycombinator.com 6y ago

Generate API Documentation in AsciiDoc Format Using OpenAPI Generator

wing328hk
2pts0
news.ycombinator.com 6y ago

Show HN: Auto-Generate Nim API Client for REST APIs

wing328hk
3pts0
github.com 6y ago

OpenAPI Generator (REST API Code Generator) v4.1.2 Released

wing328hk
1pts0
news.ycombinator.com 6y ago

Show HN: Convert OpenAPI spec to gRPC, Protobuf definitions in 3 steps

wing328hk
2pts0
github.com 6y ago

OpenAPI Generator v4.1.1 released with a new Apache Avro schema generator

wing328hk
2pts0
github.com 6y ago

OpenAPI Generator (REST API Code Generator) v4.1.0 Released

wing328hk
4pts0

I agree with you that some generators are less mature. For example, we just added a Crystal client generator several weeks ago and we only have tests for posting a JSON body and getting it back to verify the result. Features like oneOf, anyOf are not yet supported (of course we welcome contributions to improve the Crystal client generator).

You can use customized templates (e.g. via -t option in the CLI) to meet your unique requirements. Another tips is to use code formatter such as https://prettier.io/, eslint etc to format the auto-generated code based on the style you want.

Please open an issue via http://github.com/OpenAPITools/openapi-generator/issues/new if you need help with OpenAPI Generator.

Disclosure: I'm the top contributor to OpenAPI Generator

FYI. OpenAPI Generator supports many programming languages and server-side frameworks: https://github.com/OpenAPITools/openapi-generator#overview

This is not to say it has more languages supported than Protobuf as I do not know exactly how many generators out there supporting Protobuf.

(OpenAPI Generator also comes with the generator/converter that converts OpenAPI spec documents into gRPC and protocol buffer schema files. Not sure if OpenAPI Generator is also counted as a generator for Protobuf)

Does OpenAPI generate code for you? I have worked on projects that use it and didn't have any generated code, so I am assuming not...

Please give OpenAPI Generator [1] a try to generate clients, servers stubs, documentation, schemas (graphql, protobuf, etc) and more. It supports many programming languages and many companies are already using it [2]:

[1] https://github.com/OpenAPITools/openapi-generator

[2] https://openapi-generator.tech/users

(Disclosure: I'm the top contributor to OpenAPI Generator)

If you want to access RESTful APIs via OCaml, you may consider using OpenAPI Generator to generate the OCaml client automatically instead of manually creating one. Here are 3 simple steps to do so:

1. Download the OpenAPI Generator CLI Java JAR (https://repo1.maven.org/maven2/org/openapitools/openapi-gene...)

2. Rename the JAR as "openapi-generator-cli.jar"

3. Run the following command to generate an OCaml API client for the Petstore API (https://raw.githubusercontent.com/OpenAPITools/openapi-gener...):

Mac/Linux:

$ java -jar openapi-generator-cli.jar generate -g ocaml -i https://raw.githubusercontent.com/OpenAPITools/openapi-gener... -o /var/tmp/ocaml/

Windows:

$ java -jar openapi-generator-cli.jar generate -g ocaml -i https://raw.githubusercontent.com/OpenAPITools/openapi-gener... -o C:\tmp\ocaml

If you've any feedback or question, please let us know via https://github.com/OpenAPITools/openapi-generator/issues/new

Do you mind opening an issue via http://github.com/OpenAPITools/openapi-generator/issues/new with the details? (I assumed you've checked out the auto-generated documentation and that doesn't look good to you.)

There were discussions on type hints but unfortunately no one has found the time to make the contribution yet.

We also have a new `python-experimental` client generator that has better support for new features in OAS v3. Please check it out to see if it works better for you.

For C++, I don't think anyone has contributed the OAUTH2 enhancement to the C++ client generator (cpp-qt5, cpp-restsdk) yet. We definitely welcome the contributions.

For Java, I agree there are rooms for improvements as we cover so many different libraries (jersey2, retrofit2, openfeign, resttemplate, etc) and a good starting point is https://github.com/OpenAPITools/openapi-generator/tree/maste... and we can plot the OAuth-related enhancements back to the template more easily.

I remember there were discussions about adding typing to the Python client before but I don't think anyone has time to implement it yet. If you've time to make the contribution, please let me know by opening an issue/ticket: https://github.com/OpenAPITools/openapi-generator/issues/new

We've also added a protobuf schema generator (`protobuf-schema`) to convert OpenAPI spec v2,v3 to protocol buffer schemas. Please give it a try to see if it helps in your use cases.

I'm the top contributor to both OpenAPI Generator and Swagger Codegen. Just want to share a bit more to ensure everyone is on the same page.

OpenAPI Generator is a fork of Swagger Codegen. The fork took place in May 2018 - a year ago. For the reasons behind the fork, please refer to the Q&A (https://github.com/OpenAPITools/openapi-generator/blob/maste...).

Fast forward to today, we just released OpenAPI Generator v4.0.0 - the 20th release since the fork, thanks to the awesome contributions from the vibrant developer community. Please refer to the release note (https://github.com/OpenAPITools/openapi-generator/releases/t...) for more information about the release.

For a list of companies and open-source projects using OpenAPI Generator in production, please refer to the project's README (https://github.com/OpenAPITools/openapi-generator/#4---compa...).

I hope you will find OpenAPI Generator useful in your work and personal projects.

We've made some enhancements [1](e.g. OpenAPI 3.0 support) to the Python Flask generator in OpenAPI Generator. For aiohttp support in the Python Flask generator, I don't think anyone is working on that. Please let us know if you've time to make the contribution by opening an issue to start with and we can work with you to make it happen.

(OpenAPI Generator is a fork of Swagger Codegen. For the reasons behind the fork, please refer to the Q&A [2])

[1] https://github.com/OpenAPITools/openapi-generator/pulls?q=is...

[2] https://github.com/OpenAPITools/openapi-generator/blob/maste...

Sorry to hear your negative experience with Swagger Codegen regarding the PRs. Having been "managing" the project for a few years, I agree with you that I've not done a very good job in reviewing and merging all the PRs (239 open PRs as of today) contributed by the awesome community.

Myself and 40+ top contributors have decided to fork Swagger Codegen so as to maintain a community-driven version called OpenAPI Generator [1] with a better governance structure to move the project forward. Now there are 10+ core team members and contributors with proper rights to merge PRs so I think we've better PR management in OpenAPI Generator. Please refer to the Q&A [2] for the reasons behind the fork.

For TypeScript generators, we've recently added the TypeScript Axios client generator [3] and there's an ongoing project to consolidate the TypeScript generators into one [4]. Please check these out and let us know if you've any feedback.

We hope you will find OpenAPI Generator useful in your projects.

[1] https://openapi-generator.tech [2] https://github.com/OpenAPITools/openapi-generator/blob/maste... [3] https://twitter.com/oas_generator/status/1041939441109983232 [4] https://github.com/OpenAPITools/openapi-generator/projects/4

Given the Swagger/OpenAPI spec for the DB, one can use Swagger Codegen [1] (free, open-source) to generate API clients, server stubs and API documentations.

Currently the project supports more than 40+ API client generators (C#, Swift, C++, TS, JS, etc) and 20+ server stub generators (C# Nancy, Python Flask, etc). For a full list, please refer to the project README.

[1] https://github.com/swagger-api/swagger-codegen

Discloure: I'm a top contributor to the project.