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!

Metadata

Release files for django-swagger-render 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for django-swagger-render 0.1.1
File Size Uploaded
django-swagger-render-0.1.1.tar.gz 2.5 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for django-swagger-render 0.1.1
File Interpreter ABI Platform
django_swagger_render-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 4.9 MB

Release files / django-swagger-render-0.1.1.tar.gz

Download URL django-swagger-render-0.1.1.tar.gz
Size 2.5 MB
Tags Source
SHA-256 checksum
How to use checksums
77e7f284128cc00d9e217481c7d1d606a9bc523e836e1e992247478725f8aab9
BLAKE2b-256 checksum
How to use checksums
734beac667ca903853dc194a5415af5510e8d4d99561114617c6a1ba183f6e14
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.0.9 CPython/3.8.0 Linux/4.15.0-1028-gcp

Release files / django_swagger_render-0.1.1-py3-none-any.whl

Download URL django_swagger_render-0.1.1-py3-none-any.whl
Size 2.5 MB
Tags Python 3
SHA-256 checksum
How to use checksums
5da8c3dfa43a5754516fdf259f056373df55803e43f9b572a3fe6e3d4d212d69
BLAKE2b-256 checksum
How to use checksums
fda0dbf06aafc0c7a7aeff0b2ea96b9ec96a9d3f7586f42dfbbb69419a2622ef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.0.9 CPython/3.8.0 Linux/4.15.0-1028-gcp

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page