I am getting a com_id in the url later I want to valiate serializer now I dont know how to pass it to that serializer as the only data has been passed is what you get in the request methid here
class JoinCommitteeView(APIView):
def post(self, request, com_id):
data = request.data
print('data', data, com_id)
serializer = JoinCommitteeSerializer(data=data)
if serializer.is_valid(raise_exception=True):
serilizer.py
def create(self, validated_data):
print('user_id', validated_data)
how to acess that com_id here so I can create the object here