Reading facebook direct messages - facebook-graph-api

Is it possible to read direct messages using the facebook graph api? I can see a reference to a message object in the docs (http://developers.facebook.com/docs/reference/api/message/) but can’t see a call to get a collection of messages for a facebook page.

I eventually found this in the notifications call in the graph api ...
https://graph.facebook.com/id/notifications
I needed manage_notifications and read_mailbox extended permissions for this to work as well

using graph api and fql you can read messages
see https://developers.facebook.com/docs/reference/fql/ thread and message
be aware there is any difference for FB backend if a message has been sent from during online chat or while offline from chat

Related

Workaround to instagram_manage_messages for reading instagram direct messages

I have a backend application doing requests to the conversations endpoint of Graph API to fetch direct messages on instagram.
I failed to be granted the instagram_manage_messages permission as my app doesnt provide a frontend where the reviewer can test things. Apparently, they really want to play with the frontend, even when there's no frontend...
My question is : Is there any other permission we can use to fetch instagram messages from Graph API (only read operations)?
Thanks all.

Is it possible to send and fetch Facebook messages using Graph API for v4.0 or greater?

I want to create a web application using PHP which will allow to connect Facebook accounts with my application and once they authenticated my application can fetch inbox messages of that user and can auto reply to the messages received against authenticated Facebook accounts.
Also, allow user to send messages manually from my application to Facebook inbox.
Is this possible with Graph API or any other Facebook API which will allow me to do above mentioned things.
Some people was told that this feature is no longer available after Facebook Graph API v2.4.
and once they authenticated my application can fetch inbox messages of that user and can auto reply to the messages received against authenticated Facebook accounts.
Neither of those two things is possible.
You can not read the messages of user accounts any more, and you can not reply in their name either.
The only messaging that can be handled via API, is that between a user and a page.
Assuming you refer to Page conversations, not user conversation, see /conversations and /messages docs here:
https://developers.facebook.com/docs/graph-api/reference/page/conversations/
https://developers.facebook.com/docs/graph-api/reference/v5.0/conversation/messages

Can I send message to a page using Facebook Graph API?

I saw that is possible to use Graph API to send message to a user, but I didn't find nothing about send message to a page. Is it possible?
It is not possible with the API, you can only reply to a User message as Page. Sending messages from Users to Pages is not really neccessary, Users can just use the Messenger for that. Prefilling would not be allowed anyway.

Can I send facebook message to a non friend?

I'm looking at the "Messeger Platform API" documentation, and was not clear to me if I can use any Facebook API to:
Send a message from a page to a public profile.
Send a message from a facebook profile to another who is not my friend.
The Messenger Platform is not for user to user communcation. Read the docs to find out what it is about, and how to use it: https://developers.facebook.com/docs/messenger-platform

How to track messages from Facebook API

I´m trying to track messages sent to my Facebook friends.
For example: I sent a message to James Bond, how do I know if he read it or not?
The Facebook Graph API does not support this yet - http://developers.facebook.com/docs/reference/api/message/. I suspect this is because there is no guaranteed way to see if a message has been read or not based on how the user accesses their messages.
It would also require permission tokens to be passed in a three-legged (recipient to application, recipient to sender) verification.