I'm creating a site where I want to show Instagram posts. I need access_token, so I'm following the flow, trying to get "code" Once it worked, but never again...
The message is always
"{"error_type": "OAuthException", "code": 400, "error_message": "Invalid scope field(s): basic,user_profile,user_media"}"
string authUri = "https://api.instagram.com/oauth/authorize/?client_id=" + _clientID +
"&redirect_uri=" + redirectUri +
"&scope=user_profile,user_media" +
"&response_type=code";
Process.Start(authUri);
I've tried to remove scope line, then the error is Invalid scope field(s): basic When I used with scope=basic, same message, Invalid scope field(s): basic
I've tried with Instagram clientID/token, same error, tried with Instagramm ID/Secret in Facebook App, same error.
Any ideas maybe ?
Thanks in advance
Yeah, the API has been deprecated today (June 30th).
The URL should be https://www.instagram.com/oauth/authorize/?client_id=CLIENTID&redirect_uri=REDIRECTURI&response_type=code&scope=instagram_graph_user_media
but as @david wrote before me, something is broken right now because the "basic" permission is added into any request.
UPDATE July 4, 2020
Got it fixed. Had to create a new Instagram app from Facebook , then replace the client ID with the new one, update client secret, update the call URLs, create new test users, update the tokens, and generally update the entire code because the returned results from the endpoints are completely different format now. Quite some work. But it is working now.
This started happening yesterday.
Instagram deprecated the basic
scope on Jun 29 (yesterday). It looks like they might have a bug that causes basic
to be added to any valid scopes that you ask for. This seems to be, in effect, disabling the whole oauth functionality.
Hopefully they will fix this? But who knows.
You might just have to wait.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With