pavelk2 / social-feed

JavaScript plugin that shows a user feed from the most popular social networks
http://pavelk2.github.io/social-feed-example/
MIT License
962 stars 304 forks source link

Instagram problems #197

Open 8adg opened 8 years ago

8adg commented 8 years ago

can't display data from instagram. why? thanks from Argentina!

RTSRUS commented 8 years ago

you need to get here client id https://www.instagram.com/developer/ then get a token - and paste the token in the Social feed Read more here http://instagram.pixelunion.net/

HartLarsson commented 8 years ago

@8adg is better you not grant access to your instagram to 3rd part application. Just follow the instagram instructions i used and PLEASE BEFORE POST NEW ISSUES. CHECK IF ARE ALREADY ANSWERED; SEARCH IN ALL ISSUES THREADS!!!!:

I've the original script working simple getting from here: https://www.instagram.com/developer/

CLIENT ID
CLIENT SECRET
WEBSITE URL
REDIRECT URI
SUPPORT EMAIL   

now using your "CLIENT ID" and "REDIRECT URI" call this url replacing with your values:

https://api.instagram.com/oauth/authorize/?client_id=CLIENT-ID&redirect_uri=REDIRECT-URI&response_type=token you will get the right TOKEN to use.

I've made this and all works perfectly!

HartLarsson commented 8 years ago

for what i know is impossible to pull from 2 diff accounts because the token is created per account(?) I don't remember if i've tested two accounts, i oly use one instagram at time. One solution could be to use two istances configured with 2 ids and tokens. I sonly a suppose i've not tested it.

eakoranteng commented 8 years ago

Create an app and generate an access token from https://www.instagram.com/developer/. Alternatively, you can generate an access token from http://instagram.pixelunion.net/ uncheck Disable implicit OAuth under Security

For it to work with the latest instagram API changes, you will only need your access token.

Here's a sample request with access token fb2e77d.47a0479900504cb3ab4a1f626d174d2d

instagram:{
    accounts: ['&fb2e77d'],  //Array: Specify a list of accounts from which to pull posts
    limit: 5, //Integer: max number of posts to load
    access_token: 'fb2e77d.47a0479900504cb3ab4a1f626d174d2d' //String: Instagram access token
}

This worked for me. I have not tried with multiple accounts.

puijob commented 7 years ago

@HartLarsson the URL you posted that generates the Token didn't work for me. It looks like it's missing a parameter, &scope=public_content. Here is the URL that worked for me:

https://www.instagram.com/oauth/authorize/?client_id=CLIENT_ID&redirect_uri=REDIRECT_URI&response_type=token&scope=public_content

Of course, you'll have to replace CLIENT_ID and REDIRECT_URI with your values.