如何使用 Graph API 获取页面/用户/应用程序的域列表?

发布于 2025-01-02 11:07:43 字数 1082 浏览 2 评论 0 原文

我正在尝试使用 Facebook 的 Graph API 来获取用户的见解数据,并将其显示在他们的管理面板中,作为其自定义 CMS 的一部分。

我的 Facebook 集成有几个步骤: 1. 认证 2. 获取用户的页面、应用程序和域的列表 3.获取每个页面、应用程序和域的见解数据

以上所有内容都有效,但我找不到列出用户拥有的所有域的方法。我正在使用 https://graph.facebook.com/me/accounts 获取列表用户的帐户数。这将返回所有页面和应用程序,但不返回域。

我浏览了 Facebook 的所有文档,但找不到任何有关检索列表的方法的参考。

我尝试过https://graph.facebook.com/domainshttps://graph.facebook.com/me/domainshttps://graph.facebook.com/domain,以及https://graph.facebook.com/me/domain - 无济于事。 https://graph.facebook.com/domainhttps://graph.facebook.com/domains 有效,但仅在您知道域名时才有用。

那么问题来了:有没有办法使用 Graph API 获取用户的域列表?

谢谢

I'm trying to use Facebook's Graph API to grab a user's insights data, and display it in an admin panel for them, as a part of their custom CMS.

There are a few steps to my Facebook integration:
1. Authenticate
2. Get a list of pages, applications, and domains for the user
3. Get insights data for each page, application and domain

All of the above are working, but I can't find a way to list all the domains a user has. I'm using https://graph.facebook.com/me/accounts to get the list of accounts for the user. This is returning all the Pages and Applications, but no Domains.

I have looked all over Facebook's docs, and can't find any reference to a method for retrieving a list.

I have tried https://graph.facebook.com/domains, https://graph.facebook.com/me/domains, https://graph.facebook.com/domain, and https://graph.facebook.com/me/domain - to no avail. https://graph.facebook.com/domain and https://graph.facebook.com/domains are valid, but are only useful if you know the domain.

So, the question: Is there a way to obtain a list of domains for a user using the Graph API?

Thanks

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

骄兵必败 2025-01-09 11:07:43

尝试此图形 API 调用:https://graph.facebook.com/fql?q=SELECT domain_name, domain_id FROM domain WHERE domain_id in ( SELECT domain_id FROM domain_admin WHEREowner_id=me())&access_token=VALIDUSERACCESSTOKENOFTHEOWNEROFTHEDOMAIN< /代码>

try this Graph API call: https://graph.facebook.com/fql?q=SELECT domain_name, domain_id FROM domain WHERE domain_id in ( SELECT domain_id FROM domain_admin WHERE owner_id=me())&access_token=VALIDUSERACCESSTOKENOFTHEOWNEROFTHEDOMAIN

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文