django-swagger-ui
django-swagger-ui copied to clipboard
Django swagger UI is a viewer for Swagger YAML files as html.
================= Django Swagger UI
Django swagger UI is a viewer for Swagger YAML files as html. based on swagger-yaml-to-html.py <https://gist.github.com/oseiskar/dbd51a3727fc96dcf5ed189fca491fb3>_.
Quick start
-
Install the lib:
pip install django-swagger-ui
-
Add "swagger_ui" to your
INSTALLED_APPSsetting like this::INSTALLED_APPS = [ ... 'swagger_ui', ... ]
-
Include the swagger ui URLconf in your project
urls.pylike this::path('', include('swagger_ui.urls')),
-
Add this variable
SWAGGER_YAML_FILEtosettings.pypointing to your YAML file -
You will find the swagger api documentation in
/api-doc/.
.. image:: screenshots/1.png