cosenary / Instagram-PHP-API

An easy-to-use PHP Class for accessing Instagram's API.
http://cosenary.github.com/Instagram-PHP-API
BSD 3-Clause "New" or "Revised" License
1.46k stars 782 forks source link

'public_content' scope giving error #189

Open washeul opened 8 years ago

washeul commented 8 years ago

Error: getLoginUrl() - The parameter isn't an array or invalid scope permissions used.Error: getLoginUrl() - The parameter isn't an array or invalid scope permissions used.

RobWiddick commented 8 years ago

I'm submitting a fix for this in my pull request. Coming soon!

RobWiddick commented 8 years ago

Sent fix. Make sure your instagram app has been reviewed so that it has access to those new scopes.

portey commented 8 years ago

Hi, @cosenary , what about merging in to origin?

hiteshkanani commented 8 years ago

You can generate your custom authurl like this

$authUrl = 'https://api.instagram.com/oauth/authorize'; $_scopes = array('basic', 'likes', 'comments', 'relationships', 'public_content'); $url = $authUrl . '?client_id=' . env('INSTAGRAM_KEY') . '&redirect_uri=' . urlencode(env('INSTAGRAM_REDIRECT_URI')) . '&scope=' . implode('+', $_scopes) . '&response_type=code'; return redirect()->to($url);

ashrafhesham92 commented 8 years ago

Hi @cosenary , I am facing this error right now , i am still in sandbox not live to make a review , any idea what should i do please? Thanks

hiteshkanani commented 8 years ago

See above my comment.

ashrafhesham92 commented 8 years ago

@hiteshkanani Thank you very much