-
Notifications
You must be signed in to change notification settings - Fork 60
Take a serious look at generating this client from Swagger #215
Comments
I've used the |
I tried to generate API client with swagger based on the api-docs ~3 years ago. The problem there IIRC was that the API docs were not consistent with the true state of the API, making the generated code pretty much unusable. (this is not a useful piece of info) I also remember feeling it turned up much harder to do than it sounds (to simply generate api client based on json description). |
I believe if the swagger/openapi is well done then I'm convinced that the generated SDK should be good. Of course one cannot expect it to be perfect without human intervention. Also it is a good thing to keep SDKs standardized. |
Looking at #228 I've just tried to use swagger on api-docs.json. These were the issues:
|
I tried to generate and run a client with go-swagger. This is my test repo, I put some notes to README: |
A little update on the progress here:
|
This work has the potential to be a #213 implementation. |
The Equinix Metal API is available via Swagger (OpenAPIv2) at https://api.equinix.com/metal/v1/api-docs/.
Given the availability of https://goswagger.io/ and https://github.com/OpenAPITools/openapi-generator-cli we should be able to build a template (
docker run --rm -v $PWD:/local openapitools/openapi-generator-cli:v5.0.0-beta2 meta
) or set up options that will allow for a partial client to be built from the swagger spec.X-
Swagger parameters might be needed for this to be successful? (x-nullable: true
?)The text was updated successfully, but these errors were encountered: