Facebook Graph API返回空电子邮件 [英] Facebook Graph API returning an empty email

查看:89
本文介绍了Facebook Graph API返回空电子邮件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有权限访问用户的电子邮件。脚本工作正常。有数千条记录,全部都有正确的电子邮件,但有一些记录有一个空字符串(5:1000)。



我知道如果用户拒绝发送他的电子邮件,然后Facebook生成一个临时的。因此,情况并非如此。



发生了什么?有没有电子邮件地址的用户?

解决方案

临时/代理电子邮件地址是用户权限对话框中的一个选项可以选择提供给你而不是真正的地址,这不是自动的。



有些用户在他们的个人资料上没有电子邮件地址(例如您必须同时检查用户是否已经授予您



电子邮件扩展许可和/或其后续未被撤销。您可以使用用户或应用访问令牌

调用 /< USER> / permissions 如果您可以确认用户帐户中有一个有效的电子邮件地址,那么他们已经授予您的应用权限来查看他们的电子邮件,并且他们没有随后阻止该应用或撤消该权限,因此可能是API的一个错误(在这种情况下,请通过 http://developers.facebook.com/bugs 提交报告) p>

I have the permissions to access user's email. The script works fine. There are several thousands of records, all with correct email, but some of them have an empty string (5:1000).

I know that if user refuses to give out his email, then Facebook generates a temporary one. Thus, this is not the case.

What is happening? Can there be a user without email address?

解决方案

The temporary/proxy email address was an option in the permissions dialog that the user could opt to provide you instead of their real address, it wasn't an automatic thing.

Some users don't have an email address on their profiles (e.g. users that signed up via mobile phone before it was mandatory to also provide an email address).

You should also check if the user has definitely granted you the email extended permission and / or it hasn't subsequently been revoked. You can do this with a call to /<USER>/permissions with the user or app access token

If you can confirm that the user has an active email address on their account, they've granted your app permission to view their email, and they haven't subsequently blocked the app or revoked the permission, it may be a bug with the API (in which case please file a report at http://developers.facebook.com/bugs )

这篇关于Facebook Graph API返回空电子邮件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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