ESSS / flask-restalchemy

Flask extension to build REST APIs based on SQLAlchemy models
http://flask-restalchemy.readthedocs.io
MIT License
36 stars 3 forks source link

Better Swagger spec generation #26

Open igortg opened 6 years ago

igortg commented 6 years ago

Currently, Swagger spec is generated using Flasgger. But to use Flasgger, each REST resource must have its unique class, leading to the hackish code at resourcefactory.py.

Find a better way to generate Swagger specs (maybe made an script available to compile the spec based on the models registered on the API).

wgwz commented 3 years ago

Are there any better methods for creating swagger documentation nowadays? Any examples available?

igortg commented 3 years ago

One way would be to generate the docs base on the serializer class that is being used within the endpoint or resource (instead of the resource itself). I think FastAPI does something like that.