I created a test app for development mode and i associated 3 test users. Also, i created a custom story graph but the action is not approved by Facebook because it needs to post by a test user.
I tried to post the action with the three test users. The action works fine but is not shown on the wall neither on the TL.
If i check the Activity Log i can see the post but is marked as Allowed on timeline and if i want to show on TL i must edit the post and mark Shown on timeline.
How can i show the post directly on the wall and timeline and get the approve from Facebook?
I post the code for it can be useful for someone:
if (response.status === 'connected') {
// Post image using the app details
FB.api(
'me/{namespace_test}:{action}', 'post',
{
{object}: {
"url": imageUrl,
"title": "Sample title",
"image": imageUrl
}
},
function(response) {
console.log("post ok");
}
);
} else if (response.status === 'not_authorized') {
FB.login( function( response ) {
}, {scope: "publish_actions"} );
} else {
FB.login( function( response ) {
}, { scope: "public_profile" } );
}
Aucun commentaire:
Enregistrer un commentaire