I'm trying to get wall posts from a certain user using the JavaScript Facebook SDK. When I use the graph API Explorer, it works fine; but when I try the same thing on my website, I get the following error:
code: 104
message: "An access token is required to request this resource."
type: "OAuthException"
Where can I find my access token, so that I can show my company's Facebook page stream on my website?
Yes, you need an Access Token to fetch posts made by a Facebook Page. As the page posts are public, any access token will work. You should use an app access token as it never expires.
App Token.Make calls to the graph API to fetch page posts
https://graph.facebook.com/pageID/feed?access_token=your_token
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