class WindowsMacAddress(models.Model):
    address = models.TextField(unique=True)
mapping = models.ForeignKey('imaging.WindowsMapping', related_name=
    'macAddresses')

def __str__(self):
    return self.address


class WindowsCompleteMappingSerializer(serializers.Serializer):
    id = serializers.Field()
macAddresses = serializers.RelatedField(many=True)
Как настроить вывод сериализаторов Django Rest Framework?