feat(api): finish Group A stubbed endpoints
Implements previously-stubbed /api/v1 endpoints (hexagonal: ports -> repos
-> services -> routers wired in deps):
- playlists: GET /{id}/cover (serves stored cover, 404 when absent)
- settings: GET/PATCH /settings + GET/PUT /settings/scrobbling — lazy
per-user row, write-only Fernet-encrypted scrobble session key; adds
user_settings table + migration (chains off dc126696f5a6)
- storage: GET /duplicates, /broken, /missing-metadata + admin POST
/cleanup (arq cleanup_storage worker; reconciles local refs only,
guarded against a storage-outage mass delete)
- admin: GET /services, /sources, /settings + POST /reindex; PATCH
/settings and /sources/{source} return 501 (config is env-managed)
Adds NotSupportedError (-> HTTP 501). Integration tests for each surface.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -14,6 +14,7 @@ from app.infrastructure.db.models.play_history import PlayHistoryModel
|
||||
from app.infrastructure.db.models.playlist import PlaylistModel, PlaylistTrackModel
|
||||
from app.infrastructure.db.models.track import TrackModel
|
||||
from app.infrastructure.db.models.user import RefreshTokenModel, UserModel
|
||||
from app.infrastructure.db.models.user_settings import UserSettingsModel
|
||||
|
||||
__all__ = [
|
||||
"AlbumModel",
|
||||
@@ -27,4 +28,5 @@ __all__ = [
|
||||
"RefreshTokenModel",
|
||||
"TrackModel",
|
||||
"UserModel",
|
||||
"UserSettingsModel",
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user