Hey everyone,
i'm building a facebook application with the javascript sdk and i want to let the user invite one or more friends to use the application.
i want to let the user open the request dialog and choose his friends to invite.
i have 2 questions about this issue:
1) is this the right way to do so? or shuld i use regular message dialog?
2) i read here: https://developers.facebook.com/docs/reference/dialogs/requests/
that i must delete the request after it has been accepted.
how can i delete it? do i have to store the request id on my side? if so, how?
and how can i know if the request accepted? and than how do i delete it?
i cant find answers for those issues in the facebook docs.
Thanks a lot
Related
I'm dealing with bots in my app and a costumer ask me to auto detect the bot`s messages in a conversation.
When an app create a post I can see who wrote the post with: me/posts?fields=admin_creator
But when someone wrote a message in a conversation how can I see who wrote this message in the conversation API me/conversations?fields=messages
Edit:
I need to know who answer the message through my page. It was me, a bot, an app or other person who have the permission to answer by my page.
Solution #1
By reading the docs, I found this information that could help you:
It's not possible to request a message by its individual message ID. Instead you should get the message as part of the thread it's a part of.
Note that the message object has from and to objects, so
Taken from the Graph API Message docs.
Solution #2
If that doesn't help You, I'm sure these two posts from the chatbotsmagazine will:
In the post about a Swell app, the poster asks the question:
How could you identify the user? We have existing users in our
database who signed up with Facebook. There are two different user-ids
though, according to Facebook’s Docs:
(..) Ids are page-scoped. These ids differ from those returned from Facebook Login apps which are app-scoped. You must use ids retrieved from a Messenger integration for this page in order to function properly.
Then, they provided the answer to that question in this post:
FB Messenger Bot 🤖 — How to Identify a User via Page- & App-Scoped User-ID’s
I hope this helps.
Suppose that a user logged into facebook on my website. On my website they write that they want to send a message to facebook. Then after some time I will log in and click to submit the message for this user.
From what I read so far it seems that this will not be possible but I want to make sure. From what I understood, once the user logs in on my website I get an access token and only using this access token can I send a message to facebook for that user. But I would think that the access token doesn't last for a long time so it won't help saving it in a DB.
Question: is there a way to do the above mentioned functionality?
You might be able to do it through Facebook maybe something like this or maybe look here (similar question, you might find useful answer)
There have many people asking around how to send private inbox message by graph api, i search for long time, the answer is no. the reason is "App must be on whitelist"
Alternate solution is send by chat api (xampp). but this is not my solution. coz html message is not supported in chat api.
I know dropbox can do it, may i ask how to whitelist my app in Facebook to send inbox message?
I have the same requirement for an app that I am developing and I haven't been able to find any explicit directions on how to get onto the "white list".
However, my suspicion is that you need to apply to get into the Preferred Marketing Developer Program
At least, this is what Facebook says you need to do to get white listed to use the Ads API:
The Ads API is a restricted platform which may only be accessed by whitelisted Apps. You can learn more about the program and apply online. You need to apply separately for each app.
I am also struggling with this question for a while now.
I've posted my question on the facebook.stackoverflow.com site: http://facebook.stackoverflow.com/questions/13587441/facebook-invite-friends-functionality-for-multiple-recipients-custom-message
Isn't there any way of handling this issue? Help is highly appreciated!
is there a way to do this?
Using the me/home json feed, it shows up as a person and just one image of the person they have friended, even if they have friended several.
Is there a way to pull in all the information?
The most efficient way to achieve this is by using the Graph API Real Time Updates, there's no need to pull the home feed. You should be able to subscribe to the "friends" connection of the "user" object you need so your "callback server URL" will be hit by our servers when that user gets new friends (POST Request).
Note that you will only be able to retrieve the user's new friends public information unless they have previously authorized your App.
Please see further documentation at:
https://developers.facebook.com/docs/reference/api/realtime/
Many thanks
Daniel Torvisco - Developer Support Engineer at Facebook
I am going to develop a site where I want to subscribe users from facebook.
If the user subscribe successfully then application will post on his wall when something new happen in our site.
can anybody help me about this.
Thank you in advance
you will need to request "publish_stream" permissions from the user. Read the information about 'publishing' in this link.
The call will look something like this (using the facebook sdk) :
$facebook->api('/'.$user_id.'/feed','post',$post_details);
where $post_details is an array containing pictures, descriptions, links... etc..
Read from the link - it is all explained there...
Good luck!