Quick Overview: Django REST API in 2021

Django REST Framework, Source: https://www.django-rest-framework.org/

Django REST framework (DRF)is a powerful and flexible toolkit for building Web APIs. DRF is an toolkit for the Django library.

What is Django?

What is a REST API?

6 guiding constraints define a RESTful system:

  1. Client–server architecture
  2. Statelessness
  3. Cacheability
  4. Layered System
  5. Uniform interface
  6. Code on Demand (optional)

(see https://en.wikipedia.org/wiki/Representational_state_transfer)

Why using a REST

  • Scalability: The clear separtion between client and server makes it a lot easier to scale an application. Also its built upon a HTTP protocol and its stateles. Stateless means it wont share anything between other request. So any request can go to any Server in a load balanced cluster. There is nothing forcing this user request go to this server
  • Flexibility: You can use any kind of front-end library for your view and because backend and frontend is clearly seperated you can easly switch to another frontend technology.

Best resource in 2021 to learn DRF

Good look for your next project.

Django and React developer who loves to build apps. Get your latest news about Django and React by subscribing

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store