0

I´m using API Grapgh Facebook trying to Post in the Wall of a {User-id}.

I use this:

POST /v2.3/{user-id}/feed HTTP/1.1 Host: graph.facebook.com

message=This+is+a+test+message

with the token for the application.

enter image description here

It returns "(#200) The user hasn't authorized the application to perform this action" but the user-id has permission "publish_actions".

I don't know why I have not permission

user1253414
  • 249
  • 1
  • 8
  • 17
  • So I think you need to get a page token from your user token to gain permissions. See [manage_pages](https://developers.facebook.com/docs/facebook-login/permissions#reference-manage_pages) for more information. You then would use that page access key such as described in this [answer](http://stackoverflow.com/questions/4432426/which-facebook-permissions-allow-for-posting-to-a-page-wall-not-profile-wall) – Dean Coakley May 10 '17 at 08:48
  • The {user-id} is not a page, it is a personal acount, it is necessary manage_page and publish_pages? – user1253414 May 10 '17 at 09:08
  • That doesn’t look like a user access token, but an app access token. Switch to a user access token. – CBroe May 10 '17 at 09:25

1 Answers1

0

You cannot post to another user's wall without their permissions to your app.

Post on your wall with user access token, tag your friend see example here

  • Before trying to post in the application, the user has been registred in the application and he has given permission to publish_actions and I save his {user-id}. I know that I can Post with Post "me/feed" but for this, it is necessary to be logged but I would like to Post with /10023424234/feed when the user is not logged. – user1253414 May 10 '17 at 11:38
  • Then you are out of luck my friend. Facebook disabled/removed this option long ago. See another post http://stackoverflow.com/questions/14190877/how-to-post-on-a-friends-timeline-after-the-february-2013-migration-takes-effec – Fahad Habib May 10 '17 at 14:32
  • Here is link to FB https://developers.facebook.com/docs/apps/migrations/completed-changes Removing the ability to post to friends' timelines via API We have found that posting content via API (stream.publish) on a friend's wall lead to a high incidence of user dissatisfaction (hiding content, blocking the app). After the migration period, posting content to friends' timelines via stream.publish will no longer be allowed. Please use the Feed Dialog for posting. – Fahad Habib May 10 '17 at 14:35