          self.create_valid(serializer)
          headers = self.get_success_headers(serializer.data)
          return Response(serializer.data, status=status.HTTP_201_CREATED, headers=headers)
  
      def create_valid(self, serializer):
          serializer.save()
  
      def get_success_headers(self, data):
          try:
              return {'Location': data[api_settings.URL_FIELD_NAME]}
 
</s> remove         self.create_valid(serializer)
 </s> add         self.perform_create(serializer) </s> remove     def update_valid(self, serializer):
 </s> add     def preform_update(self, serializer): </s> remove         self.update_valid(serializer)
 </s> add         self.preform_update(serializer) </s> remove     def save(self, *args, **kwargs):
        instance = super(MySerializer).save(*args, **kwarg)
 </s> add For example:

    def perform_create(self, serializer):
        # Include the owner attribute directly, rather than from request data.
        instance = serializer.save(owner=self.request.user)
        # Perform a custom post-save action.
    def perform_create(self, serializer):
          self.create_valid(serializer)
          headers = self.get_success_headers(serializer.data)
          return Response(serializer.data, status=status.HTTP_201_CREATED, headers=headers)
  
    def perform_create(self, serializer):
          serializer.save()
  
      def get_success_headers(self, data):
          try:
              return {'Location': data[api_settings.URL_FIELD_NAME]}
keep keep keep keep replace keep keep keep keep keep
 Tweak pre/post save hooks. Return instance in .update(). 
rest_framework/mixins.py