API Access to the Notes To give our web application an API we are going to be using the REST framework. For our API to work correctly we need to provide ways for the application to serialize data, that is, convert the database objects into JSON. We will need to create a serializer object for each of the data objects we want to be able to access. Firstly, we need to create the directory structure so go ahead and create the following directories/files inside our notes/ folder:
Securing the Application Now that we can view our notes on the website, we are going to want a login system. Currently anyone can navigate to our website and see all of our notes. Not ideal. To secure our site we will be using a combination of Djangos built-in auth module and crispy forms. First off we will add the auth modules URLs to the project so open up the URLs file in the project directory and add the following.