soundwave/backend/appsettings/views.py
Iulian 51679d1943 Initial commit - SoundWave v1.0
- Full PWA support with offline capabilities
- Comprehensive search across songs, playlists, and channels
- Offline playlist manager with download tracking
- Pre-built frontend for zero-build deployment
- Docker-based deployment with docker compose
- Material-UI dark theme interface
- YouTube audio download and management
- Multi-user authentication support
2025-12-16 23:43:07 +00:00

37 lines
1.1 KiB
Python

"""App settings API views"""
from django.conf import settings
from rest_framework.response import Response
from appsettings.serializers import AppConfigSerializer
from common.views import ApiBaseView, AdminOnly
class AppConfigView(ApiBaseView):
"""Application configuration endpoint"""
def get(self, request):
"""Get app configuration"""
config = {
'app_name': 'SoundWave',
'version': '1.0.0',
'sw_host': settings.SW_HOST,
'audio_quality': 'best',
'auto_update_ytdlp': settings.SW_AUTO_UPDATE_YTDLP,
}
serializer = AppConfigSerializer(config)
return Response(serializer.data)
class BackupView(ApiBaseView):
"""Backup management endpoint"""
permission_classes = [AdminOnly]
def get(self, request):
"""Get list of backups"""
# TODO: Implement backup listing
return Response({'backups': []})
def post(self, request):
"""Create backup"""
# TODO: Implement backup creation
return Response({'message': 'Backup created'})