diff options
| author | Paul Buetow <paul@buetow.org> | 2026-05-21 08:38:29 +0300 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2026-05-21 08:38:29 +0300 |
| commit | 1edf0e1add29f7f342d38b595a7a563a75414d0c (patch) | |
| tree | 693137c689b8118960cad73231832fc235bc765a /player-android/lib/api | |
| parent | 09f0ee28b6a7b7fc588a8a4e387d94ffb6848af3 (diff) | |
Implement MediaDetailScreen with metadata, favorite toggle, player routing (ya)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'player-android/lib/api')
| -rw-r--r-- | player-android/lib/api/player_api_client.dart | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/player-android/lib/api/player_api_client.dart b/player-android/lib/api/player_api_client.dart index 9e67d9e..e9d99a0 100644 --- a/player-android/lib/api/player_api_client.dart +++ b/player-android/lib/api/player_api_client.dart @@ -144,6 +144,15 @@ class PlayerApiClient { String thumbnailUrl(int mediaId) => '${rawDio.options.baseUrl}/api/v1/media/$mediaId/thumbnail'; + /// Returns the URL used to stream a media item. + /// + /// Mirrors [thumbnailUrl]: the API path `/api/v1/media/{id}/stream` is kept + /// in one place and Dio internals are never leaked into the UI layer. + /// The base URL is derived from the underlying Dio instance so it stays + /// consistent with every other API call. + String streamUrl(int mediaId) => + '${rawDio.options.baseUrl}/api/v1/media/$mediaId/stream'; + Future<void> regenerateThumbnail(int mediaId) => throw UnimplementedError(); Future<bool> toggleFavorite(int mediaId) => throw UnimplementedError(); |
