开发者

How can a Facebook Platform website using Facebook's API send invites to a user's friends?

I realize these questions have been asked before on Stackoverflow, but now that FBML is being deprecated, it seems like the answer may have changed.

I have a website that utilizes the Facebook API, which in current terminology I believe makes it a Facebook Platform website. This is now a Facebook Canvas App, which are apps that appear on Facebook itself in iframes.

The Requests Dialog would seem perfect for this, if not for the fact that it's tailored for sending invites for Canvas Apps, and in my case, the Canvas App is simply a blank pa开发者_运维知识库ge assigned to me when I got a Facebook API key. I suppose I could just put a welcome screen and a link on that page for users to click-through, but it's one more click and that much more friction, and a generally hackish approach.

I've found references indicating there was once a way for users to utilize FBML to send an Application Invite, which is not the same as a Request Dialog, such that when a recipient click Accept, they were sent to a URL instead of a Facebook Canvas App. However, as I noted, FBML is in the process of being deprecated.

In light of this, how can a non-Canvas website allow users to send invites to their Facebook friends?


The requests dialog is currently the only supported way. As as alternative you can use the old Facebook REST API to call notifications.sendEmail, which will send the user an email either to their actual email account or their Facebook mail account. That page says that an equivalent graph API method will eventually come to replace this method.


I ended up using the Request Dialog, and hosting on my canvas page a redirect as per: Redirect User to my Website on a Facebook Canvas Page

Gave the nod still to OffBySome's answer, though, because of his useful information that led me to settle on the Request Dialog.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜