Skip to content

Files

Latest commit

author
Alpha Teds Technology
May 24, 2020
96749bb · May 24, 2020

History

History
9 lines (8 loc) · 748 Bytes

README.md

File metadata and controls

9 lines (8 loc) · 748 Bytes

django-rest-api

This is the very basic version of REST API using Django framework of Python. This app contains the name and alais as the model and we have serialized them using REST API. This is the basic idea of REST API of Django, using the same concept you can make powerful APIs.

djangorestframework

The Django's djangorestframework is very powerful tool for generating the rest API from our model. There are simple steps for creating the rest API in Django.

  1. Create a Model ( Here we have created a model "HERO" with Name and Alias )
  2. Create serailizers.py ( Here we define which model we want to work with and make a serializer class )
  3. Create a view for the Serliazer ( the framework does for you )
  4. Create a URL for the view