[Answered ]-How to pass model instance to serializer?

1👍

I’m not sure how your models look like but it sounds like you could use Nested relationships you in serializer. It would make your view much simpler and you would not have to worry about passing the instance to the next serializer.

rest_framework does not support write if you have a nested serializer though. So you have to either write a custom method for create() (example in docs). Or use drf-writable-nested

Leave a comment