$npx skillfedfor your agent

django-ninja-extra

Django Ninja Extra - Class Based Utility and more for Django Ninja(Fast Django REST framework)

Worth itPyPI Software DevelopmentReleased Jul 2026408.9K downloads / mopermissive licensePure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — django_ninja_extra-0.31.6-py3-none-any.whl
v0.31.6 · released 2026-07-21 · Python >=3.7 · 5 runtime deps: Django, django-ninja, injector, asgiref, contextlib2

Yes. This is an actively maintained, permissive-licensed extension to Django Ninja with low install friction and no known vulnerabilities. Install it if you're building a Django REST API and prefer class-based organization with dependency injection; skip it if you're committed to function-based simplicity.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Low friction: pure Python wheel with five runtime dependencies (Django, django-ninja, injector, asgiref, contextlib2).
  • Actively maintained with a release 24 days ago and 594 repository stars.

License · maintenance · safety

permissive license (permissive) — MIT license (permissive) means you can use this freely in commercial and private projects with minimal restrictions.

last release 2026-07-21 (24 days) · last repo commit 2026-08-11 · 594 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 408,881 downloads/mo, #6,874 on PyPI

Verify before relying

pip install django-ninja-extra

# In settings.py
INSTALLED_APPS = [..., 'django_ninja_extra']

# In api.py
from django_ninja_extra import NinjaExtraAPI, api_controller, http_get

api = NinjaExtraAPI()

@api_controller('/math')
class MathController:
    @http_get('/add')
    def add(self, a: int, b: int):
        return {"result": a + b}

api.register_controllers(MathController)
  • Whether the injector dependency works seamlessly with all Django versions listed (3.1 through 6.0) in practice.
  • Performance characteristics compared to Django alone when handling high request volumes.
  • Exact module import paths and whether 'ninja_extra' or 'django_ninja_extra' is the canonical import name.
Same gist for agents: .md · .json

What it is and what it does

Django Ninja Extra is a class-based extension for Django Ninja that organizes REST API endpoints into controller classes rather than scattered function decorators. It adds controller-level and route-level permission systems, built-in dependency injection via the injector package, and a service layer pattern for business logic separation. The package inherits Django Ninja's Pydantic-based validation, async support, and automatic OpenAPI documentation while layering on organizational patterns for larger APIs.

You use it by decorating controller classes with @api_controller, defining handler methods with @http_get/@http_post/etc., and registering them with your NinjaExtraAPI instance. Dependencies are automatically resolved and injected into controller constructors. It supports custom permission classes at both controller and individual route levels, making it suitable for APIs with complex authorization requirements. The package maintains compatibility with Django versions 3.1 through 6.0 and Python 3.8 and later.

Use it for

  • Build modular REST APIs by grouping related endpoints into controller classes with shared dependencies and permissions.
  • Implement fine-grained permission control at both controller and individual route levels for complex authorization schemes.
  • Inject services and repositories into controllers for clean separation between API handlers and business logic.
  • Migrate from Django Ninja to a framework with familiar class-based patterns while retaining async-first performance.
  • Generate interactive API documentation automatically via OpenAPI/Swagger without manual schema definitions.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

Worth it

Yes.

This is an actively maintained, permissive-licensed extension to Django Ninja with low install friction and no known vulnerabilities. Install it if you're building a Django REST API and prefer class-based organization with dependency injection; skip it if you're committed to function-based simplicity.

Install

django-ninja-extra on PyPI

Before you install

Low friction: pure Python wheel with five runtime dependencies (Django, django-ninja, injector, asgiref, contextlib2). Actively maintained with a release 24 days ago and 594 repository stars.

License in practice

MIT license (permissive) means you can use this freely in commercial and private projects with minimal restrictions.

Quickstart

pip install django-ninja-extra

# In settings.py
INSTALLED_APPS = [..., 'django_ninja_extra']

# In api.py
from django_ninja_extra import NinjaExtraAPI, api_controller, http_get

api = NinjaExtraAPI()

@api_controller('/math')
class MathController:
    @http_get('/add')
    def add(self, a: int, b: int):
        return {"result": a + b}

api.register_controllers(MathController)

Verify before relying

  • Whether the injector dependency works seamlessly with all Django versions listed (3.1 through 6.0) in practice.
  • Performance characteristics compared to Django alone when handling high request volumes.
  • Exact module import paths and whether 'ninja_extra' or 'django_ninja_extra' is the canonical import name.

Package facts

Licensepermissive license permissive
Python supportSupports the current Python release >=3.7
Install frictionLow. Pure-Python wheel
Runtime dependencies
5 packages
Djangodjango-ninjainjectorasgirefcontextlib2
MaintenanceActively maintained 24 days since the last release
Last repo commit
First released
Downloads408,881 / month, #6,874 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 5 - Production/StableEnvironment :: Web EnvironmentFramework :: AsyncIOFramework :: DjangoFramework :: Django :: 3.1Framework :: Django :: 3.2Framework :: Django :: 4.1Framework :: Django :: 4.2Framework :: Django :: 5.0Framework :: Django :: 6.0Intended Audience :: DevelopersIntended Audience :: Information TechnologyIntended Audience :: System AdministratorsLicense :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Topic :: InternetTopic :: Internet :: WWW/HTTPTopic :: Internet :: WWW/HTTP :: HTTP ServersTopic :: Software DevelopmentTopic :: Software Development :: LibrariesTopic :: Software Development :: Libraries :: Application FrameworksTopic :: Software Development :: Libraries :: Python ModulesTyping :: Typed

Evidence: django_ninja_extra-0.31.6-py3-none-any.whl

Tags

Capabilities
django rest api class-based viewsdjango ninja controllersdependency injection djangodjango api permissionsasync django rest framework
Topics
class-based-viewsdependency-injectionasync-first

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “django rest api class-based views”

  • django-ninja-extraDjango Ninja Extra extends Django Ninja with class-based controllers,…
  • adrfAdds async/await support to Django REST framework views, viewsets,…
  • django-bracesProvides reusable mixin classes for Django class-based views,…

Give your agent the search over MCP, or paste the wish link into any chat.

More Software Development packages

typing-extensions Worth it
PyPI · Software Development · released Jul 2026

Provides backported and experimental type hints for Python 3.9+, allowing use of newer typing features on older Python versions and enabling early experimentation with type system PEPs before they enter the standard library.

PSF-2.0pure Python · 3.9+
1.9Bdownloads / mo
numpy Worth it
PyPI · Software Development · released Aug 2026

NumPy provides an N-dimensional array object and a comprehensive suite of mathematical, linear algebra, Fourier transform, and random number functions for scientific computing in Python.

BSD-3-Clause AND 0BSD AND MIT AND Zlib AND CC0-1.0compiled wheel · 3.12+
1.1Bdownloads / mo
fastapi Worth it
PyPI · Software Development · released Jul 2026

FastAPI is a Python web framework for building REST APIs using type hints, with automatic request validation, serialization, and interactive API documentation.

MITpure Python · 3.10+
568.6Mdownloads / mo
annotated-doc With conditions
PyPI · Software Development · released Jul 2026

Provides a way to document function parameters, class attributes, return types, and variables inline using Python's `Annotated` type hint syntax instead of traditional docstrings.

MITpure Python · 3.9+
456.2Mdownloads / mo
typer Worth it
PyPI · Software Development · released Aug 2026

Typer builds command-line applications from Python functions using type hints, automatically generating help text, argument parsing, and shell completion.

Install it if you are building CLIs in Python.

MITpure Python · 3.10+
369.3Mdownloads / mo
distlib With conditions
PyPI · Software Development · released Jun 2026

Distlib provides low-level packaging utilities for building, distributing, and managing Python software—including metadata handling, version specifiers, wheel support, script installation, and dependency resolution.

permissive licensepure Python
323.3Mdownloads / mo

See also django-ninja · django-ninja-jwt · django-extra-views · django-service-objects · django-ratelimit · django-braces · django-decorator-include · django-admin-extra-buttons · Flask-Injector · django-adminplus