| Both sides previous revisionPrevious revisionNext revision | Previous revision |
| onny:jellyfin [2019/04/18 18:42] – [public share audio] 2a01:4f8:191:327:d4a0:1eff:fee2:65e8 | onny:jellyfin [2021/10/31 10:42] (current) – external edit 127.0.0.1 |
|---|
| | ===== Further api findings ===== |
| | Information about currently logged in user |
| | <code> |
| | /Users/Public?format=json |
| | </code> |
| | ===== Exclude playlists Jellyfin server ===== |
| | <code> |
| | ./Emby.Naming/Common/NamingOptions.cs: ".flac", |
| | ./MediaBrowser.Model/Dlna/MediaFormatProfile.cs: FLAC, |
| | ./MediaBrowser.Model/Dlna/MediaFormatProfileResolver.cs: if (StringHelper.EqualsIgnoreCase(container, "flac")) |
| | ./MediaBrowser.Model/Dlna/MediaFormatProfileResolver.cs: return MediaFormatProfile.FLAC; |
| | ./MediaBrowser.Model/Net/MimeTypes.cs: if (StringHelper.EqualsIgnoreCase(ext, ".flac")) |
| | ./MediaBrowser.Model/Net/MimeTypes.cs: return "audio/flac"; |
| |
| | </code> |
| | <file - MediaBrowser.Controller/Playlists/Playlist.cs> |
| | [...] |
| | public static string[] SupportedExtensions = |
| | { |
| | ".sos" |
| | }; |
| | [...] |
| | </file> |
| | |
| | ===== Convert Plex playlists ===== |
| | <code> |
| | https://turbotux.de/Users/{user_id}/Items?api_key={api_key}&IncludeItemTypes=Playlist&format=json |
| | https://turbotux.de/Users/eb8c2ec5352843d3a16ca11c26d3551c/Items?api_key={api_key}&IncludeItemTypes=Playlist&format=json |
| | https://turbotux.de/Users/eb8c2ec5352843d3a16ca11c26d3551c/Items?api_key=a5dc4ea2f58d490db39c9e0ad204aa83&IncludeItemTypes=Playlist&format=json |
| | https://turbotux.de/Users/eb8c2ec5352843d3a16ca11c26d3551c/Items?api_key=a5dc4ea2f58d490db39c9e0ad204aa83&IncludeItemTypes=Playlist&format=json |
| | |
| | https://turbotux.de/Items?format=json&Recursive=true&IncludeItemTypes=Playlist&api_key=MYAPIKEY |
| | </code> |
| | this one is good: |
| | <code> |
| | https://turbotux.de/Users/eb8c2ec5352843d3a16ca11c26d3551c/Items?api_key=a5dc4ea2f58d490db39c9e0ad204aa83&IncludeItemTypes=Playlist&format=json&Recursive=true |
| | </code> |
| | creating playlist |
| | <code> |
| | https://turbotux.de/Playlists?UserId=eb8c2ec5352843d3a16ca11c26d3551c&Name=lolorollo&api_key=a5dc4ea2f58d490db39c9e0ad204aa83 |
| | </code> |
| | this works |
| | <code bash> |
| | curl --data "UserId=eb8c2ec5352843d3a16ca11c26d3551c&Name=lolorollo&api_key=a5dc4ea2f58d490db39c9e0ad204aa83" "https://turbotux.de/Playlists?UserId=eb8c2ec5352843d3a16ca11c26d3551c&Name=lolorollo&api_key=a5dc4ea2f58d490db39c9e0ad204aa83" |
| | </code> |
| | searching track |
| | <code> |
| | https://turbotux.de/Search/Hints?UserId=eb8c2ec5352843d3a16ca11c26d3551c&Limit=50&IncludeItemTypes=Music&SearchTerm=Catene&format=json |
| | </code> |
| | its only hint |
| | <code> |
| | https://turbotux.de/Search/Hints?UserId=eb8c2ec5352843d3a16ca11c26d3551c&SearchTerm=danke%20gut&format=json&api_key=a5dc4ea2f58d490db39c9e0ad204aa83 |
| | </code> |
| | extra fields |
| | <code> |
| | https://turbotux.de/Items?UserId=eb8c2ec5352843d3a16ca11c26d3551c&format=json&api_key=a5dc4ea2f58d490db39c9e0ad204aa83&Recursive=true&IncludeItemTypes=Audio%2CMusicAlbum%2CMusicArtist&Fields=Path&SearchTerm=Baobab%20Sira |
| | </code> |
| | |
| | ===== Import playlists Jellyfin ===== |
| | * Remove previous library: rm /var/lib/jellyfin/data/library.* |
| | * Add new library, disable real time monitoring and metadata fetching |
| | * Creating API key |
| | * Go to server settings (icon upper right corner) |
| | * Expert -> Advanced, left menu |
| | * Menu upper middle part: Security |
| | * Beside title api keys, click on the plus symbol |
| | * App name: playlist importer |
| | * Copy api key hash, something like ''a5dc4ea2f58d490db39c9e0ad204aa83'' |
| | * Get userid hash |
| | * Click on the profile icon, upper right corner |
| | * Click on profile |
| | * Copy userid hash from the url which looks like: ''myserver.com/web/index.html#!/myprofile.html?userId=eb8c2ec5352843d3a16ca11c26d3551c'' |
| | |
| | ===== audio normalization ===== |
| | <code> |
| | return _config.GetConfiguration<EncodingOptions>("encoding"); |
| | </code> |
| | <code> |
| | onny@onnuex /tmp> r128gain test.flac test_quieter.flac |
| | Analyzing loudness of file 'test.flac'... |
| | Analyzing loudness of file 'test_quieter.flac'... |
| | File 'test.flac': loudness = -13.2 LUFS, sample peak = -0.5 dBFS |
| | File 'test_quieter.flac': loudness = -20.6 LUFS, sample peak = -7.8 dBFS |
| | Tagging file 'test.flac' |
| | Tagging file 'test_quieter.flac' |
| | </code> |
| | <code> |
| | Apr 09 18:02:43 picloud dotnet[10436]: [18:02:43] [INF] /usr/bin/ffmpeg -i file:"/mnt/audio/music/Mac Demarco/All Of Our Yesterdays (Single)/01 All Of Our Yesterdays.flac" -map_metadata -1 -map_chapters -1 -threads 0 -acodec aac -strict experimental -ac 2 -vn -f segment -max_delay 5000000 -avoid_negative_ts disabled -start_at_zero -segment_time 3 -individual_header_trailer 0 -segment_format mpegts -segment_list_type m3u8 -segment_start_number 0 -segment_list "/var/lib/jellyfin/transcoding-temp/6d88998728f39c3666d33c311a1bbb33.m3u8" -y "/var/lib/jellyfin/transcoding-temp/6d88998728f39c3666d33c311a1bbb33%d.ts" |
| | </code> |
| | <file - MediaBrowser.Api/Playback/Hls/BaseHlsService.cs> |
| | return string.Format("{0} {1} -map_metadata -1 -map_chapters -1 -threads {2} {3} { 4} {5} -f segment -max_delay 5000000 -avoid_negative_ts disabled -start_at_zero -segment_time {6} {10} -individual_header_trailer 0 -segment_format {11} -segment_list_entry_prefix {12} -segment_li st_type m3u8 -segment_start_number {7} -segment_list \"{8}\" -y \"{9}\"", |
| | [...] |
| | var args = string.Format("{0} {1} {2} -map_metadata -1 -map_chapters -1 -threads {3} { 4} {5} -max_delay 5000000 -avoid_negative_ts disabled -start_at_zero {6} -hls_time {7} -individual _header_trailer 0 -start_number {8} -hls_list_size {9}{10} -y \"{11}\"", |
| | </file> |
| | ===== public share audio ===== |
| | * https://turbotux.de/web/index.html#!/itemdetails.html?id=c575c67bdbfbdfaa394a481757296f97&serverId=d86b3ad0a9ea49beb834c0caca75c13a |
| | * https://github.com/jellyfin/jellyfin-web/blob/master/src/itemdetails.html |
| | * http://localhost:8096/web/index.html#!/itemdetails.html?id=9cf4001dc9b153f8637d660b66628ea4&serverId=913db02421064ec4a463b9d37df63597 |
| | jellyfin fetching json when logged in: |
| | * http://localhost:8096/emby/Users/df721abec56e46738da5e99a8ea90865/Items/9cf4001dc9b153f8637d660b66628ea4 |
| | it will require an access token! same page without login |
| | * http://localhost:8096/emby/Items/9cf4001dc9b153f8637d660b66628ea4 |
| | lets achieve something like |
| | * http://localhost:8096/emby/Users/Guest/Items/9cf4001dc9b153f8637d660b66628ea4 |
| | <file javascript jellyfin-web/src/components/appRouter.js> |
| | // if (apiClient && apiClient.isLoggedIn()) { |
| | // |
| | // console.log('appRouter - user is authenticated'); |
| | // |
| | // if (route.isDefaultRoute) { |
| | // console.log('appRouter - loading skin home page'); |
| | // loadUserSkinWithOptions(ctx); |
| | // return; |
| | // } else if (route.roles) { |
| | // |
| | // validateRoles(apiClient, route.roles).then(function () { |
| | // |
| | // callback(); |
| | // |
| | // }, beginConnectionWizard); |
| | // return; |
| | // } |
| | // } |
| | </file> |
| | <file javascript jellyfin-web/src/bower_components/apiclient/apiclientcore.js> |
| | var url = userId ? this.getUrl("Users/" + userId + "/Items/" + itemId) : this.getUrl("Users/Guest/Items/" + itemId); |
| | </file> |
| | now it fails on backend userid validation |
| | <code> |
| | Input string was not in a correct format. |
| | </code> |
| | Internal server error http://localhost:8096/emby/Users/Guest/Items/9cf4001dc9b153f8637d660b66628ea4 |
| | * System.FormatException: Input string was not in a correct format. |
| | * /jellyfin-10.3.1/Emby.Server.Implementations/Services/StringMapTypeDeserializer.cs |
| | * /jellyfin-10.3.1/Emby.Server.Implementations/Services/ServicePath.cs |