I registered my application on Spotify. I made sure the URI is added to my registered application. But still, every time I run this code, I still get the same error. I also manage this in the background, so I know that it is not. What am I doing wrong?
I also tried switching /spotify to /provider_cb .
var client_id = '<my_client_id>'; var redirectUri = chrome.identity.getRedirectURL() + "/spotify"; chrome.identity.launchWebAuthFlow({ "url": "https://accounts.spotify.com/authorize?client_id="+client_id+ "&redirect_uri="+ encodeURIComponent(redirectUri) + "&response_type=token", 'interactive': true, }, function(redirect_url) { console.log(redirect_url); });
Here's my driver license:
"permissions": [ "http://*/*", "tabs", "webNavigation", "activeTab", "storage", "identity", "declarativeContent", "https://accounts.spotify.com/*", "https://accounts.spotify.com/authorize/*" ]
The first time I launch my application after restarting Chrome, the login page appears, as if everything is in order, but after logging in I still get the same error:
identity.launchWebAuthFlow: Authorization page could not be loaded.
source share