Closed datnt closed 12 years ago
If there is the function in Graph API documents, there should be in fb_graph.
ie.)
FbGraph::User#feed!(:key => "value") # => POST /:user_id/feed?key=value
Thank you for your reply.
Could you please explain more specific about the solution.
I am able to post to multi-friends by using javascript function code as below:
function SendFBinvi(id){ FB.api('/'+id+'/feed', 'post', { message: 'my message', link:'http://localhost:3000', name:'title', picture:'', description:'my description }, function(response) { if (!response || response.error) { } else { } }); }
I'm expecting to do the same with RubyOnRails code by using fb_graph gem.
I had tried some method but for the same users (friends, which I can posted with javascript), fb_graph provide the following error:
FbGraph::Unauthorized (OAuthException :: (#200) The user hasn't authorized the application to perform this action)
That error is saying your access token doesn't have publish_stream
permission.
https://developers.facebook.com/docs/authentication/permissions/
Thank you for your hint.
1> How can I configure so that my web-application able to gain publish_stream permission ? (I've read through the document of facebook but does not gain the idea of how to make the configuration)
2> Another thing came up; In this case, if my app does not have publish_steam permission, why the javascript of FB.api works ?
Hi Nov,
Could you please explain more from the 2 statements I provided above?
I don't understand about your suggestion of "publish_stream" configuration ?
Thank you, Dat
Hi , We are using fb_graph for our app and it is great.
Could you please explain that whether there is a function of gem fb_graph that allow current_user to post message to his/her friends's wall ?
Thank you very much, Dat