title: pass url parameter to serializer
body: <p>Suppose my url be, <strong>POST</strong> : <code>/api/v1/my-app/my-model/?myVariable=foo</code></p>
  
  <p>How can I pass the <code>myVariable</code> to the serializer?</p>
  
  <pre><code># serializer.py
  class MySerializer(serializers.ModelSerializer):
      class Meta:
          fields = '__all__'
          model = MyModel
  
      def custom_validator(self):
          # how can i get the "myVariable" value here?
          pass
  
      def validate(self, attrs):
          attrs = super().validate(attrs)
          self.custom_validator()
          return attrs
  
  
  # views.py
  class MyViewset(ModelViewSet):
      queryset = MyModel.objects.all()
      serializer_class = MySerializer
  </code></pre>