# alanjds/drf-nested-routers

Nested Routers for Django Rest Framework

Repository: https://github.com/alanjds/drf-nested-routers
Canonical: https://ross.abutalabs.com/products/drf-nested-routers
Homepage: https://pypi.org/project/drf-nested-routers/
Language: Python
License: Apache-2.0
License Family: permissive
Topics: django, django-rest-framework, rest, nested-resources, hacktoberfest
Last push: 2026-08-15T03:21:59+00:00

## Health v2 (maintenance only)
Score: 85/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 97, release rhythm 62, longevity 100
- inputs: {"age_days": 4720, "days_push": 18, "days_rel": 41, "gap_med": null, "n_releases_24m": 1}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1799, forks 173 (observed 2026-08-28T04:05:37.889105+00:00)

## What it is
A Python library providing routers and fields for creating nested resources in Django REST Framework. It enables RESTful URL structures where one resource lives inside another, such as /domains/{domain_pk}/nameservers/.

## Use cases
- create nested REST API URL structures in Django Rest Framework
- route child resources under parent resources like /domains/{pk}/nameservers/
- build REST APIs where a resource cannot exist without its parent
- register nested viewsets with DRF routers
- filter child querysets by parent primary key from URL kwargs

## When to choose
- you use Django REST Framework and need hierarchical resource URLs
- your API resources have strict parent-child ownership relationships
- you want full REST URL nesting without hand-writing URL patterns

## When to avoid
- your API resources are flat and don't need nested URL structures
- you don't use Django or Django REST Framework
- you need deeply nested or highly custom routing beyond parent-child nesting

## Facets
- artifact type: library
- maturity: active
- function: routing, api-framework, web-framework
- domain: web-development, backend, apis
- platform: python
- tags: django, django-rest-framework, rest-api, nested-resources, url-routing

## Member repositories
- alanjds/drf-nested-routers (main) score 85

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:37.889105+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T03:22:16.737924+00:00, confidence not recorded.
  - readme: https://github.com/alanjds/drf-nested-routers (fetched 2026-08-28T04:05:37.889105+00:00, sha cf17232233b6)
  - homepage: https://pypi.org/project/drf-nested-routers/ (fetched 2026-08-29T11:01:09.313910+00:00, sha 4b4e8fead74a)
  - registry_pypi: https://pypi.org/pypi/drf-nested-routers/json (fetched 2026-08-29T11:01:09.323197+00:00, sha 14385ee97c91)
- Data as of 2026-08-30T08:39:29.467469+00:00.
