Skip to main content

Django Swagger Render

Getting Started

Prerequisites

  • python >= 3.5
  • Django >= 2.0

Installation

Install using pip

pip install django-swagger-render

Add 'swagger_render' to your INSTALLED_APPS setting.

INSTALLED_APPS = [
    ...
    'swagger_render',
]

Create the folder where you will store your documentation

mkdir docs

Create the index.yml file with some OPENAPI or Swagger specifications

touch docs/index.yml

Serve your documentation files

urlpatterns += static('/docs/', document_root='docs')

Add SWAGGER_YAML_FILENAME setting to your settings.py

SWAGGER_YAML_FILENAME = '/docs/index.yml'

Add the SwaggerUIView to your urls

from swagger_render.views import SwaggerUIView


urlpatterns = [
    ...
    path('swagger/', SwaggerUIView.as_view()),
]

Voila!

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-swagger-render-0.1.1.tar.gz (2.5 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

django_swagger_render-0.1.1-py3-none-any.whl (2.5 MB view details)

Uploaded Python 3

File details

Details for the file django-swagger-render-0.1.1.tar.gz.

File metadata

  • Download URL: django-swagger-render-0.1.1.tar.gz
  • Upload date:
  • Size: 2.5 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.0.9 CPython/3.8.0 Linux/4.15.0-1028-gcp

File hashes

Hashes for django-swagger-render-0.1.1.tar.gz
Algorithm Hash digest
SHA256 77e7f284128cc00d9e217481c7d1d606a9bc523e836e1e992247478725f8aab9
MD5 f1d7436ead6298228e0f757c637ce96f
BLAKE2b-256 734beac667ca903853dc194a5415af5510e8d4d99561114617c6a1ba183f6e14

See more details on using hashes here.

File details

Details for the file django_swagger_render-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for django_swagger_render-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 5da8c3dfa43a5754516fdf259f056373df55803e43f9b572a3fe6e3d4d212d69
MD5 c9bfcad8966a61592c4ecdb6eccfb596
BLAKE2b-256 fda0dbf06aafc0c7a7aeff0b2ea96b9ec96a9d3f7586f42dfbbb69419a2622ef

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 files

0.1.0

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page