In this chapter, we will improve the Django RESTful API with a PostgreSQL 10.5 database that we started in the previous chapter. We will use many of the features included in Django REST framework to add new functions to the API and will add authentication-related security to it. We will do the following:
- Add unique constraints to the models
- Update a single field for a resource with the PATCH method
- Take advantage of pagination
- Customize pagination classes
- Understand authentication, permissions, and throttling
- Add security-related data to the models
- Create a customized permission class for object-level permissions
- Persist the user that makes a request and configure permission policies
- Set a default value for a new required field in migrations
- Compose requests with the necessary authentication
- Browse the API with authentication...