class MembershipSerializer(serializers.HyperlinkedModelSerializer):
    id = serializers.Field(source='group.id')
name = serializers.Field(source='group.name')


class Meta:
    pass
Include intermediary (through model) in responses in Django Rest Framework