Skip to main content

A comprehensive Django app that provides visualization and analysis of your DRF backend.

Project description

DRF Inspector

DRF Inspector is a powerful developer tool for analyzing, visualizing, and understanding Django REST Framework (DRF) backends.

It automatically inspects your project architecture and provides interactive visualizations for:

  • API endpoints
  • serializers
  • models
  • relationships
  • views
  • query optimization
  • security analysis
  • architecture exporting

DRF Inspector helps developers debug, document, optimize, and better understand complex DRF projects.


✨ Features

🌐 API & URL Analysis

  • Inspect all DRF endpoints automatically
  • Detect HTTP methods (GET, POST, PATCH, etc.)
  • View connected views and serializers
  • Search and filter endpoints

🧠 Model Visualization

  • Auto-generate model relationship graphs
  • Visualize:
    • ForeignKey
    • ManyToManyField
    • OneToOneField
  • Interactive relationship mapping

🔍 Serializer Inspection

  • Detect serializers used in views
  • Inspect serializer fields
  • Detect nested serializers
  • Show serializer → model mappings

🧭 View Analysis

  • Analyze:
    • authentication classes
    • permission classes
    • pagination
    • throttling
    • filtering
  • Supports DRF class-based views and ViewSets

🔒 Security Audit

  • Detect endpoints missing:
    • authentication
    • permissions
    • throttling
  • Helps identify insecure API routes

⚡ Query Optimization Detection

  • Detect possible N+1 query issues
  • Suggest:
    • select_related
    • prefetch_related
  • Analyze queryset optimization opportunities

📦 Exporting

Export project architecture as:

  • JSON
  • Markdown

Useful for:

  • documentation
  • architecture reviews
  • team sharing
  • AI context sharing

🖥️ Interactive Dashboard

  • Built directly into Django
  • No React required
  • No external frontend setup
  • Works instantly inside your project

🔗 Links


📸 Screenshots

Dashboard

URL Explorer

Model Relationships

Serializer Inspector

Query Optimization


⚡ Installation

Step 1: Install the package

pip install drf-inspector==0.1.3

Step 2: Add in settings.py:

installed_apps = [
  drf_inspector,
   ....
]

Step 3: Add in project urls.py:

from django.urls import path, include
urlpatterns = [
  ...,
  path("drf-inspector/",include("drf_inspector.urls")),
]

Final Step : Go to the url and that's it:

   http://127.0.0.1:8000/drf-inspector/

Project details


Download files

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

Source Distribution

drf_inspector-0.1.3.tar.gz (19.8 kB view details)

Uploaded Source

Built Distribution

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

drf_inspector-0.1.3-py3-none-any.whl (29.8 kB view details)

Uploaded Python 3

File details

Details for the file drf_inspector-0.1.3.tar.gz.

File metadata

  • Download URL: drf_inspector-0.1.3.tar.gz
  • Upload date:
  • Size: 19.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.4

File hashes

Hashes for drf_inspector-0.1.3.tar.gz
Algorithm Hash digest
SHA256 97d014e965d8c0739975a51fdd6d5cd9911175afa6e5a587d839967f2cdcabc1
MD5 34d4e97955972ec5a4a935794f05d3d0
BLAKE2b-256 ed544ec3843b475004861fd88d159e7d93b90ba4bbed3908063b79ec10d250d3

See more details on using hashes here.

File details

Details for the file drf_inspector-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: drf_inspector-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 29.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.4

File hashes

Hashes for drf_inspector-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 cc3f0bc3d5f59766494590612ce918cea9cd8a3d78292abae4edc2d7edb224ee
MD5 8ba0130e4637bb67e1233c978e906ce7
BLAKE2b-256 f662ce9bf6640e8d99ecac4d97dd332eddf32077ad6df9733794c9165dcf97f3

See more details on using hashes here.

Supported by

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