Refactor: file api in to seperate api app & use drf api views

This commit is contained in:
Aroy-Art 2025-03-19 17:35:31 +01:00
parent 1f75b1bf17
commit bd2791c155
Signed by: Aroy
GPG key ID: 583642324A1D2070
6 changed files with 150 additions and 71 deletions

View file

@ -0,0 +1,9 @@
from django.urls import path
from .views import FileServeView, FileDetailView
urlpatterns = [
# Serve the actual file
path("files/<str:file_hash>/", FileServeView.as_view(), name="serve_file"),
# Get file metadata
path("files/<str:file_hash>/info/", FileDetailView.as_view(), name="file_info"),
]