Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 

Repository files navigation

Django REST Framework (DRF) Learning Plan

Overview

This is a 10-day structured plan to learn Django REST Framework (DRF) by following the official documentation. The goal is to learn DRF concepts and build APIs effectively.

Prerequisites

Before starting, ensure you have:

  • Good knowledge of Python & Django
  • Django installed (pip install django)
  • DRF installed (pip install djangorestframework)
  • Postman or an API testing tool

Learning Schedule

Day 1: Introduction & Setup

Practice:

  • ✅ Create a Django project
  • ✅ Add DRF to INSTALLED_APPS and configure settings

Day 2: Serializers

  • Read: Serializers
  • Understand ModelSerializer vs Serializer

Practice:

  • ✅ Create a Serializer for a model
  • ✅ Convert Python objects to JSON and vice versa

Day 3: Requests, Responses & API Views

Practice:

  • ✅ Create a simple API view
  • ✅ Use different HTTP methods (GET, POST)

Day 4: Class-Based Views & Mixins

Practice:

  • ✅ Refactor API views using generic views
  • ✅ Create an API using ListCreateAPIView & RetrieveUpdateDestroyAPIView

Day 5: ViewSets & Routers

Practice:

  • ✅ Create a ModelViewSet for a model
  • ✅ Register it with DefaultRouter

Day 6: Authentication (JWT & Token-based)

  • Read: Authentication
  • Learn TokenAuthentication and JWT (using djangorestframework-simplejwt)

Practice:

  • ✅ Implement JWT authentication
  • ✅ Test authentication with Postman

Day 7: Permissions & Throttling

  • Read: Permissions
  • Learn about IsAuthenticated, IsAdminUser, Custom Permissions

Practice:

  • ✅ Restrict API access based on user roles
  • ✅ Implement custom permissions

Day 8: Pagination, Filtering & Searching

Practice:

  • ✅ Add pagination to API results
  • ✅ Implement filtering using Django filters

Day 9: API Testing & Documentation

  • Read: Testing
  • Learn about Swagger & DRF’s built-in API docs

Practice:

  • ✅ Write unit tests for APIs using Django’s test framework
  • ✅ Set up Swagger for API documentation

Day 10: Deployment & Best Practices

  • Read: Deployment
  • Learn about caching, security, and performance

Practice:

  • ✅ Deploy a DRF project on Render/Heroku
  • ✅ Optimize API performance

Additional Tips

  • Use Postman to test APIs
  • Take Notes while reading the documentation
  • Practice Daily to reinforce concepts

Next Steps

  • Explore Async Django
  • Learn Django Channels for WebSockets
  • Contribute to open-source DRF projects

Happy Learning! 🚀

About

learning journey for django-rest-framework

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors