Add LRCLIB lyrics integration for Jellyfin

- Create LrclibService to fetch lyrics from lrclib.net API
- Add LyricsInfo model for lyrics data
- Add /Audio/{itemId}/Lyrics and /Items/{itemId}/Lyrics endpoints
- Support both local and external songs
- Cache lyrics for 30 days in Redis
- Return lyrics in Jellyfin format with synced/plain lyrics
This commit is contained in:
2026-01-30 02:09:27 -05:00
parent ceaa17f018
commit f8969bea8d
4 changed files with 328 additions and 0 deletions

View File

@@ -8,6 +8,7 @@ using allstarr.Services.Validation;
using allstarr.Services.Subsonic;
using allstarr.Services.Jellyfin;
using allstarr.Services.Common;
using allstarr.Services.Lyrics;
using allstarr.Middleware;
using allstarr.Filters;
@@ -95,6 +96,7 @@ else
// Business services - shared across backends
builder.Services.AddSingleton<RedisCacheService>();
builder.Services.AddSingleton<ILocalLibraryService, LocalLibraryService>();
builder.Services.AddSingleton<LrclibService>();
// Register backend-specific services
if (backendType == BackendType.Jellyfin)