Facebook Messenger平台:如何获取用户特定的信息? [英] Facebook Messenger Platform: how to get user specific information?

查看:275
本文介绍了Facebook Messenger平台:如何获取用户特定的信息?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试最近发布的Facebook Messenger平台,到目前为止这么好。一切运行良好,我能够创建一个回声机器人。

I'm trying the recent released Facebook Messenger Platform and so far so good. Everything worked well and I was able to create a echo bot.

但我想知道如何识别这个用户开始在我的页面上聊天。例如,当用户开始聊天时,我得到一个PID用户(页面特定的用户ID)。

But I'm wondering how I could identify this user that started chatting in my page. For example, when a user started chatting I get a PID user (page specific user id).

向Facebook Graph API发出以下请求:

Making the follow request to Facebook Graph API:

GET https://graph.facebook.com/v2.6/{PAGE_SPECIFIC_USER_ID}

我发现我只需要询问以下字段:first_name,last_name和profile_pic。

I discovered that I can just ask for the following fields: first_name,last_name and profile_pic.

所以我的问题是,如何发现这个用户是否是我的业务页面的当前客户?是否有其他方式查询更多信息(如电子邮件和真实的Facebook用户ID)?

So my question is, how could I discover if this user is a current customer of my business page? Is there another way of querying more information (like e-mail and real facebook user id)?

推荐答案

目前,没有办法去做这个。最好的方法是提示用户在聊天中输入他们的信息,或者给他们链接到移动登录页面,或者通过其他方式将他们的帐户关联到聊天。

Currently, there's no way to do this. The best way would be to prompt the user to enter their information in chat or give them a link to a mobile login page or some other way of linking their account to the chat.

这篇关于Facebook Messenger平台:如何获取用户特定的信息?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆