I seen many answer related this problem but I confused how to implement this.

**My requirement is:**

(Create)**First create data with key and value:**
`{"pradip" : 80}` and store in `user_rate_details` model field.

(Update)**Second time append new data in this field :**
`{"pradip" : 80,"exz" : 70}` and save it.
How to achieve this in my views..

**models.py:**

```
    class UserPhoto(models.Model):
        user = models.ForeignKey(to = User,on_delete = models.CASCADE,related_name='userPhoto')
        ......
        rated_by = models.ManyToManyField(Profile,blank=True,related_name='rate_by')
        **user\_rate\_details = models.TextField() ⬅⬅⬅⬅⬅ Here store JSON data**
        created_date = models.DateTimeField(auto_now_add=True)
```

**views.py:**

```
    class PhotoRate(APIView):
        permission_classes = [IsAuthenticated]

        def get_userPhoto(self,pk):
            try:
                return UserPhoto.objects.get(id = pk)
            except UserPhoto.DoesNotExist:
                raise Http404

        def post(self,request,formate = None):
            pk = request.data.get('photo_id')
            rate = request.data.get('rate')
            **photo = self.get\_userPhoto(pk)
 ???????? How to create or update Json data here???
 return Response(??JSON DATA??)**
```

Any other best way you know please tell me..

Thank you..