--- id: djangorestframework-recursive version: "0.1.2" license: BSD license_treatment: permissive maintenance: dormant --- # djangorestframework-recursive — Recursive Serialization for Django REST framework License: permissive · Maintenance: dormant · Downloads: 267.2K/mo ## What it is and what it does djangorestframework-recursive provides a RecursiveField that handles serialization and deserialization of recursive data structures in Django REST Framework. Instead of writing custom recursive logic or nested serializers, you can use RecursiveField as a child of a ListField to represent tree nodes, linked lists, or acyclic graphs. The package claims to support validation, deserialization, ModelSerializers, and multi-step recursive structures. The package is in Pre-Alpha status and has been dormant since its latest release. It was tested against Python 2.7, 3.4, and 3.6; Django 1.8–2.0; and DRF 3.3–3.7. No runtime dependencies are required beyond Django and DRF themselves, making installation straightforward. However, the lack of recent maintenance and pre-release status mean compatibility with modern Python, Django, and DRF versions is unverified. Use it for: - Serialize a tree of categories or organizational hierarchies in a REST API without manually nesting serializers - Handle linked-list structures like comment threads with replies in JSON responses - Deserialize and validate recursive JSON payloads representing graphs or nested structures - Build a ModelSerializer for Django models with self-referential foreign keys ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Adds a RecursiveField to Django REST Framework that serializes and deserializes tree structures, linked lists, and directed acyclic graphs without writing custom recursive logic. No—unless you are maintaining legacy code on Django 1.8–2.0 and DRF 3.3–3.7. The package is Pre-Alpha, dormant since 2017, and untested against modern versions. For new projects, use built-in DRF nested serializers or a maintained alternative. The lack of recent updates and pre-release status create risk of incompatibility and unresolved bugs. ## Install pip install djangorestframework-recursive uv add djangorestframework-recursive poetry add djangorestframework-recursive ## Installing djangorestframework-recursive Before you install: Low install friction with no runtime dependencies. Dormant since July 2017; last commit August 2024 suggests minimal maintenance. Pre-Alpha status and lack of recent activity mean expect limited support for modern Django or DRF versions. License in practice: BSD license is permissive; you can use, modify, and distribute this package freely in most contexts without restriction. Quickstart: pip install djangorestframework-recursive from djangorestframework_recursive.fields import RecursiveField class TreeSerializer(serializers.Serializer): name = serializers.CharField() children = serializers.ListField(child=RecursiveField()) Requires Django and Django REST Framework to be installed separately; tested against Django 1.8–2.0 and DRF 3.3–3.7, but compatibility with modern versions is unverified. Verify before relying: - Whether RecursiveField works with current versions of Django (3.2+) and Django REST Framework (3.12+) - Whether validation and deserialization work as documented in the description excerpt - Whether multi-step recursive structures are production-ready or experimental ## Package facts - License: BSD (permissive) - Python support: unspecified - Install friction: low - Maintenance: dormant - Downloads: 267.2K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags django rest framework recursive serialization, tree serialization drf, nested structure serializer, recursive field django, hierarchical data rest api, graph serialization django rest, django-rest-framework, serialization, tree-structures [View on SkillFed](https://skillfed.io/packages/djangorestframework-recursive) · [View on PyPI](https://pypi.org/project/djangorestframework-recursive/)