mirror of
https://github.com/Googolplexed0/zotify.git
synced 2026-04-24 22:05:53 +03:00
[GH-ISSUE #161] [Bug Report] FAILED TO FETCH AUDIO KEY IN PREMIUM ACCOUNT #142
Labels
No labels
bug
considering
discussion
documentation
enhancement
enhancement
good first issue
help wanted
pull-request
question
stale
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/zotify#142
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @rneweconomics26-bit on GitHub (Jan 27, 2026).
Original GitHub issue: https://github.com/Googolplexed0/zotify/issues/161
Originally assigned to: @Googolplexed0 on GitHub.
Zotify Version
v0.11.5
Bug Description
When I try to download a song or a playlist, I get this error. I have a premium account.
Bug Triggering Command
zotify --debug https://open.spotify.com/intl-es/track/0uhI1APF1D4scWNrOUCMIw?si=dfea9542ccc148ca
DEBUG
config_DEBUG.json saved to /home/roils/.config/zotify
zotify_DEBUG_2026-01-27_14-43-20.log logging to /home/roils/Music/Zotify Music
DEBUG
Session Initialized Successfully
User Subscription Type: PREMIUM
Request Parsed as 1 URL
ERROR: FAILED TO FETCH AUDIO KEY
MAY BE CAUSED BY RATE LIMITS - CONSIDER INCREASING
BULK_WAIT_TIMEGID: 100cc369e995453983ec0295baef01d8 - File_ID: bc156f413c8f0bc258648ac9fdf9a27d5f614c6b
ERROR: SKIPPING TRACK - FAILED TO GET CONTENT STREAM
Track_ID: 0uhI1APF1D4scWNrOUCMIw
Error Traceback / Logs
DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): apresolve.spotify.com:443
DEBUG:urllib3.connectionpool:https://apresolve.spotify.com:443 "GET /?type=accesspoint HTTP/1.1" 200 None
INFO:Librespot:Session:Created new session! device_id: ce54f5ef20f72468470cccb1e3dd7d45b9aeff3b, ap: ap-gew1.spotify.com:80
INFO:Librespot:Session:Connection successfully!
INFO:Librespot:Session:Session.Receiver started
DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): apresolve.spotify.com:443
DEBUG:urllib3.connectionpool:https://apresolve.spotify.com:443 "GET /?type=spclient HTTP/1.1" 200 None
DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): apresolve.spotify.com:443
INFO:Librespot:Session:Skipping 02
INFO:Librespot:Session:Received license_version: 0
INFO:Librespot:Session:Received country_code: DO
DEBUG:Librespot:Session:Parsed product info: {'type': 'premium', 'ab-ad-player-targeting': '1', 'ab-watch-now': '0', 'ab_recently_played_feature_time_filter_threshold': 'com.spotify.gaia=30,driving-mode=120,spotify%3Ainternal%3Astartpage=30', 'ad-formats-preroll-video': '0', 'ad-session-persistence': '1', 'ads': '0', 'app-developer': '0', 'audio-preview-url-template': 'https://p.scdn.co/mp3-preview/{id}', 'audio-quality': '1', 'audiobook-onboarding-completed': '0', 'autoplay': '1', 'capping-bar-threshold': '3601', 'catalogue': 'premium', 'collection': '1', 'created_by_partner': None, 'employee-free-opt-in': '0', 'enable-annotations': '2', 'enable-annotations-read': '0', 'enable-crossfade': '1', 'explicit-content': '1', 'financial-product': 'pr:premium,tc:0,rt:v2_DO_default_intro-1m_0_USD_default', 'head-file-caching': '1', 'head-files': '1', 'head-files-url': 'https://heads-fa-tls13.spotifycdn.com/head/{file_id}', 'high-bitrate': '1', 'image-url': 'https://i.scdn.co/image/{file_id}', 'incognito_mode_timeout': '21600', 'is_email_verified': '1', 'key-caching-auto-offline': '0', 'key-caching-max-count': '10000', 'key-caching-max-offline-seconds': '1800', 'key-memory-cache-mode': '1:15,300', 'libspotify': '1', 'license-agreements': None, 'loudness-levels': '1:-5.0,0.0,3.0:-2.0', 'metadata-link-lookup-modes': '0', 'mobile': '1', 'name': 'Spotify Premium', 'nft-disabled': '1', 'offline': '1', 'on-demand': '1', 'on-demand-trial-in-progress': '0', 'payments-initial-campaign': 'default', 'payments-locked-state': '0', 'player-license': 'premium', 'playlist-annotations-markup': '0', 'preferred-locale': 'en', 'prefetch-keys': '1', 'prefetch-strategy': '18', 'prefetch-window-max': '2', 'product-expiry': None, 'publish-activity': '0', 'publish-playlist': '1', 'radio': '1', 'rating-access': '1', 'remote-control': '6', 'restrict-playlist-collaboration': '0', 'send-email': '0', 'shows-collection': '1', 'shows-collection-jam': '1', 'shuffle': '0', 'shuffle-algorithm': 'FRESH', 'sidebar-navigation-enabled': '0', 'storage-size-config': '10240,90,500,3', 'streaming': '1', 'streaming-rules': None, 'ugc-abuse-report': '1', 'ugc-abuse-report-url': 'https://support.spotify.com/abuse/?uri={uri}', 'unrestricted': '1', 'video-cdn-sampling': '100', 'video-device-blacklisted': '0', 'video-manifest-url': 'https://spclient.wg.spotify.com/manifests/v6/{type}/sources/{source_id}/options/supports_drm', 'widevine-license-url': 'https://spclient.wg.spotify.com/widevine-license/v1/video/license'}
INFO:Librespot:Session:Skipping 1f
INFO:Librespot:Session:Skipping 69
DEBUG:Librespot:MercuryClient:Handling packet, cmd: 0xb5, seq: -1926976591049523200, flags: b'\x01', parts: 1
DEBUG:Librespot:MercuryClient:Couldn't dispatch Mercury event seq: -1926976591049523200, uri: hm://pusher/v1/connections/Y2U1NGY1ZWYyMGY3MjQ2ODQ3MGNjY2IxZTNkZDdkNDViOWFlZmYzYitBUCt0Y3A6Ly8wYWNhNDA0Zi5pcC5nZXcxLnNwb3RpZnkubmV0OjUwMTErRTVFRTAzQjM4OTlEMzc1NjQ4NEM3QTVCNjFBMkYyNEY4NEI0REUxNjZBMzgwOEQ3NzY2NEVDNjhFNjIwMDJCQw%3D%3D, code: 200, payload: b''
DEBUG:Librespot:Session:Received 0x10: df759f661238c1419d6599fcbb4d9931c52ab17d
DEBUG:urllib3.connectionpool:https://apresolve.spotify.com:443 "GET /?type=dealer HTTP/1.1" 200 None
DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): login5.spotify.com:443
INFO:Librespot:Session:Skipping unknown command cmd: 0x75, payload: b'\x00\x00\x01'
DEBUG:urllib3.connectionpool:https://login5.spotify.com:443 "POST /v3/login HTTP/1.1" 200 None
INFO:Librespot:TokenProvider:Login5 authentication successful, got access token
DEBUG:Librespot:TokenProvider:Using Login5 access token for scopes: ['playlist-read']
INFO:Librespot:Session:Authenticated as 31noku7gyq2vrekw2tv2wg2pitxa!
DEBUG:zotify.debug:
Session Initialized Successfully
DEBUG:zotify.debug:
User Subscription Type: PREMIUM
DEBUG:zotify.debug:
Request Parsed as 1 URL
DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): clienttoken.spotify.com:443
DEBUG:urllib3.connectionpool:https://clienttoken.spotify.com:443 "POST /v1/clienttoken HTTP/1.1" 200 None
DEBUG:Librespot:ApiClient:Updated client token: AAAZPXJdOd0YLQIURyrDv24X1/DXasBZZSfMLJvwge20oWxIrzNy+xLkKDdxLr1esjNK0UrJ213M7QYFucSfMBmEZFTWzqPZUB9yKfD7zDdJIleM7t9Dh5sUvkhdceStM24KHiV+m1DeIuWodmOFdjSsm3CgAm1odkNfsEj+a1jJLuxGz7owD2PiHIoyCJQNd3mMWnob8rFtYRgeAYQVRLHjWtdylDbiqWKijmi1H4Bd0h7/G6y8eQJNDPn66lwuEuPwDSKkLvR3Hf8=
DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): gue1-spclient.spotify.com:443
DEBUG:urllib3.connectionpool:https://gue1-spclient.spotify.com:443 "POST /extended-metadata/v0/extended-metadata HTTP/1.1" 200 842
DEBUG:urllib3.connectionpool:https://gue1-spclient.spotify.com:443 "GET /storage-resolve/files/audio/interactive/bc156f413c8f0bc258648ac9fdf9a27d5f614c6b HTTP/1.1" 200 481
CRITICAL:Librespot:AudioKeyManager:Audio key error, code: 1
CRITICAL:Librespot:AudioKeyManager:Audio key error, code: 1
ERROR:zotify.debug:
FAILED TO FETCH AUDIO KEY
MAY BE CAUSED BY RATE LIMITS - CONSIDER INCREASING
BULK_WAIT_TIMEGID: 100cc369e995453983ec0295baef01d8 - File_ID: bc156f413c8f0bc258648ac9fdf9a27d5f614c6b
ERROR:zotify.debug:
Failed fetching audio key! gid: 100cc369e995453983ec0295baef01d8, fileId: bc156f413c8f0bc258648ac9fdf9a27d5f614c6b
ERROR:zotify.debug:
SKIPPING TRACK - FAILED TO GET CONTENT STREAM
Track_ID: 0uhI1APF1D4scWNrOUCMIw
INFO:zotify.debug:
[A
Config File
{
"DEBUG": "True",
"ROOT_PATH": "
/Music/Zotify Music",/Music/Zotify Podcasts","SAVE_CREDENTIALS": "True",
"CREDENTIALS_LOCATION": "",
"OUTPUT": "",
"OUTPUT_SINGLE": "{artist}/{album}/{artist}{song_name}",
"OUTPUT_ALBUM": "{artist}/{album}/{album_num}{artist}{song_name}",
"OUTPUT_PLAYLIST_EXT": "{playlist}/{playlist_num}{artist}{song_name}",
"OUTPUT_LIKED_SONGS": "Liked Songs/{artist}{song_name}",
"ROOT_PODCAST_PATH": "
"SPLIT_ALBUM_DISCS": "False",
"MAX_FILENAME_LENGTH": "0",
"OPTIMIZED_DOWNLOADING": "True",
"BULK_WAIT_TIME": "1",
"DOWNLOAD_REAL_TIME": "False",
"TEMP_DOWNLOAD_DIR": "",
"DOWNLOAD_PARENT_ALBUM": "False",
"NO_COMPILATION_ALBUMS": "False",
"NO_VARIOUS_ARTISTS": "False",
"NO_ARTIST_APPEARS_ON": "False",
"DISCOG_BY_ALBUM_ARTIST": "False",
"REGEX_ENABLED": "False",
"REGEX_TRACK_SKIP": "",
"REGEX_EPISODE_SKIP": "",
"REGEX_ALBUM_SKIP": "",
"DOWNLOAD_FORMAT": "copy",
"DOWNLOAD_QUALITY": "auto",
"TRANSCODE_BITRATE": "auto",
"CUSTOM_FFMEPG_ARGS": "",
"SONG_ARCHIVE_LOCATION": "",
"DISABLE_SONG_ARCHIVE": "False",
"DISABLE_DIRECTORY_ARCHIVES": "False",
"SKIP_EXISTING": "True",
"SKIP_PREVIOUSLY_DOWNLOADED": "False",
"EXPORT_M3U8": "False",
"M3U8_LOCATION": "",
"M3U8_REL_PATHS": "True",
"LIKED_SONGS_ARCHIVE_M3U8": "True",
"LYRICS_TO_METADATA": "True",
"LYRICS_TO_FILE": "True",
"LYRICS_LOCATION": "",
"OUTPUT_LYRICS": "{artist}_{song_name}",
"ALWAYS_CHECK_LYRICS": "False",
"LYRICS_MD_HEADER": "False",
"BYPASS_MD_API": "True",
"LANGUAGE": "en",
"MD_DISC_TRACK_TOTALS": "True",
"MD_SAVE_GENRES": "True",
"MD_ALLGENRES": "False",
"MD_GENREDELIMITER": ", ",
"MD_ARTISTDELIMITER": ", ",
"SEARCH_QUERY_SIZE": "10",
"STRICT_LIBRARY_VERIFY": "True",
"ALBUM_ART_JPG_FILE": "False",
"RETRY_ATTEMPTS": "1",
"CHUNK_SIZE": "20000",
"REDIRECT_ADDRESS": "127.0.0.1",
"PRINT_SPLASH": "False",
"PRINT_PROGRESS_INFO": "True",
"PRINT_SKIPS": "True",
"PRINT_DOWNLOADS": "True",
"PRINT_DOWNLOAD_PROGRESS": "True",
"PRINT_URL_PROGRESS": "True",
"PRINT_ALBUM_PROGRESS": "True",
"PRINT_ARTIST_PROGRESS": "True",
"PRINT_PLAYLIST_PROGRESS": "True",
"PRINT_WARNINGS": "True",
"PRINT_ERRORS": "True",
"PRINT_API_ERRORS": "True",
"STANDARD_INTERFACE": "False",
"FFMPEG_LOG_LEVEL": "error"
}
Additional Context
i I tried to increase the "BULK_WAIT_TIME" but it didn't work
@SkilletWarez commented on GitHub (Jan 29, 2026):
mine I tried increasing to 10 bulk time. then for many tracks. sometimes I have to redownload when this appears
@2uu7 commented on GitHub (Feb 1, 2026):
I had same error, made 2 BUG issues but developer closed both, said they tested it on their own and it works without API keys. I've been using this tool for some time now, so it sucks that it's not really usable now : (
@2uu7 commented on GitHub (Feb 1, 2026):
On version 0.15.6, re-did login, updated config file, but still no success.
Everytime I try to download a track, this log generates:
zotify_2026-01-27_04-24-58.log