Using Generalized Behavior from the APIView Class

In this chapter, we will improve our simple RESTful Web Service. We will make it possible for it to work with diverse content types without writing a huge amount of code. We will take advantage of advanced features and generalized behaviors included in the Django REST framework to enable multiple parsers and renderers. We will gain an understanding of:

  • Taking advantage of model serializers
  • Understanding accepted and returned content types
  • Making unsupported HTTP OPTIONS requests with command-line tools
  • Understanding decorators that work as wrappers
  • Using decorators to enable different parsers and renderers
  • Taking advantage of content negotiation classes
  • Making supported HTTP OPTIONS requests with command-line tools
  • Working with different content types
  • Sending HTTP requests with unsupported HTTP verbs
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.133.134.151