0

我如何将我的链接附件发布到 facebook 上的群组提要?我想我做错了。

function post_to_group() {
    FB.api("/group_id/feed", 'post', {
        message: 'My Sample Post',
        attachment: {
            name: 'Article Name Slugs', 
            href: 'http://mylink.com/article-name-slugs/'
        }
         }, 
            function(response) {
            if (!response || response.error) {
                console.log('Error occured: ', response.error);
            } else {
                alert('Post ID: ' + response.id);
            }
    });
}

这是我对我所做的事情的参考: Facebook - 发布到群组页面

但这表明我的工作和我提到的工作都有错误-

{message: "(#200) 用户未授权应用程序执行此操作", type: "OAuthException", code: 200}

4

1 回答 1

0
FB.ui(
        {
            method: 'stream.publish',
            from: myId,
            to: groupID,
            attachment: {
                name: 'Post to a group Test',
                href: '...'
            }
        });
于 2014-03-07T01:32:27.197 回答