4

I read here that I can get a non-expiring access token for users when calling this:

https://graph.facebook.com/oauth/access_token?             
client_id=APP_ID&
client_secret=APP_SECRET&
grant_type=fb_exchange_token&
fb_exchange_token=EXISTING_ACCESS_TOKEN 

It is obvious what client_id and client_secret are but what the heck are grant_type and fb_exchange_token?

I managed to post something to the user's timeline/pin board but as access_token I used APP_ID + | + APP_SECRET. It worked great.

BTW: I need the permission manage_pages because I want to add photos to a user album.

Any ideas what these two attributes are and where I can get them?

1 Answer 1

5

grant type(the third parameter) is nothing but the string "fb_exchange_token"

and

fb_exchange_token(the fourth parameter) is the previous ACCESS_TOKEN that has either expired or is about to expire.

So for example your requesting URL should be something like :

https://graph.facebook.com/oauth/access_token
client_id=783921075894231403
&client_secret=78789230452234235412793042
&grant_type=fb_exchange_token
&fb_exchange_token=60as98dg690758a0sd5g57869608s9da8g6sda96g5s9adg

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.