Messenger Bot 不回复随机用户?

Messenger Bot does not reply to random user?

我会尽力解释我遇到的问题。 当我从我自己的 FB 帐户使用机器人时,一切正常。

但是当我要求其他人使用它时,机器人没有回应他们,尽管我在 dev.FB 中的 pages_messaging 上有绿色勾号。

使机器人写回复的基本 sendText 函数:

function sendText(sender, text){
    let messageData = {text : text}
    console.log("comes here too" + " message data: " +messageData);
    request({
        url: "https://graph.facebook.com/v2.6/me/messages",
        qs : {access_token : token},
        method: "POST",
        json: {
            recipient : {id: sender},
            message : messageData
        }
    }, function(error, response, body){
        if ( error){
            console.log("sending error")
        } else if(response.body.error){
            console.log("messageData: " + messageData + "recipient " + sender)
            console.log("response body error" + response + " body "+body)
        }
    })
}

我遇到的错误是其他人试图连接到机器人: 我的 3 console.logs 通过了以下内容:

comes here too message data: [object Object]

messageData: [object Object]recipient (MyOtherAccountIDIsHere)

response body error[object Object] body [object Object]

我最初的想法是机器人审查没有正常工作,页面实际上没有被批准。因为在我的开发者 FB 帐户上,我可以正常地与机器人聊天 w/o 任何问题(最后 else if with 2 console.logs 不会出现)

请让我知道您的想法,如果需要,愿意提供任何其他信息。

我犯了如此愚蠢的错误。 感谢@CBroe 的帮助。

答案:我必须转到 App Review 选项卡并单击 Make appID public?是的!