dmr-from-drf

Migrate Django REST Framework APIs to django-modern-rest while preserving routes and contracts.

1.3k|150|Updated Oct 9, 2025
One-click install
npx skills add https://github.com/wemake-services/django-modern-rest --skill dmr-from-drf
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dmr-from-drf
Source: https://github.com/wemake-services/django-modern-rest/tree/main/.agents/skills/dmr-from-drf
Command: npx skills add https://github.com/wemake-services/django-modern-rest --skill dmr-from-drf

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Migrate Django REST Framework APIs to django-modern-rest while preserving routes, request/response contracts, authentication, permissions, throttling, pagination, and test coverage.

Core Features & Use Cases

  • Incremental migration of DRF endpoints to DMR controllers and routers while preserving contracts.
  • Per-endpoint parity of routes, methods, authentication, permissions, throttling, and pagination.
  • Supports project-native batteries and tests while avoiding DRF internals in migrated slices.

Quick Start

Inventory DRF endpoints and draft a per-endpoint migration plan before implementing DMR controllers and routers.

Frequently Asked Questions about dmr-from-drf

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I migrate Django REST Framework APIs to django-modern-rest without breaking existing contracts?

To migrate Django REST Framework APIs to django-modern-rest, inventory existing endpoints and draft a per-endpoint migration plan that preserves routes, request/response contracts, authentication, permissions, throttling, and pagination while replacing DRF serializers with typed DTOs.

Can I incrementally migrate DRF ViewSets and GenericAPIViews to DMR controllers?

Yes, you can incrementally migrate DRF ViewSets and GenericAPIViews to DMR controllers and routers. The migration supports per-endpoint parity checks, allowing you to replace APIViews in stages while maintaining project-native tests and avoiding DRF internals in migrated slices.

Does migrating from DRF to DMR require changing my existing API routes and pagination?

Migrating from DRF to DMR does not require changing existing API routes and pagination. The process enforces strict per-endpoint parity, documenting observable behavior and using reference maps to ensure authentication, permissions, throttling, and pagination remain identical.

What is the best way to replace DRF serializers and routers with typed DTOs during a migration?

The best way to replace DRF serializers and routers with typed DTOs is to follow a strict migration policy that maps DRF routers to DMR routers and validates per-endpoint parity, ensuring the new typed DTOs match the original request and response contracts.

What are the limitations when migrating DRF endpoints to DMR controllers?

A key limitation when migrating DRF endpoints to DMR controllers is the requirement for strict documentation and per-endpoint parity checks. Migrated slices must avoid DRF internals entirely, meaning you cannot mix DRF serializers and DMR typed DTOs within the same migrated endpoint.

Why do I need a per-endpoint migration plan before replacing Django REST Framework with DMR?

You need a per-endpoint migration plan before replacing Django REST Framework with DMR to guarantee observable behavior remains identical. It establishes reference maps for routes, methods, and permissions, preventing contract drift and ensuring test coverage validates the new DMR controllers.