from rest_framework import serializers

class DownloaderStatsSerializer(serializers.Serializer):
    total_downloads = serializers.IntegerField()
    avg_length_of_media = serializers.FloatField(allow_null=True)
    avg_file_size = serializers.FloatField(allow_null=True)
    total_length_of_media = serializers.IntegerField(allow_null=True)
    total_file_size = serializers.IntegerField(allow_null=True)
    most_common_format = serializers.CharField(allow_null=True)