Could FB API send request to particular friend - facebook-graph-api

I know I can use FB Api to send the request, but I need to pick up those guys from my friend list. Is there a way, I can preselect the particular friends from the list or send the request directly to some particular guys?
Thank you!

You can use the Requests dialog.

Related

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.

messages API twitter Challenge-Response Checks

I've seen that twitter changed their endpoints to get and send direct messages, I noticed from a reply from here that it is a workaround to be able to send messages with well-known libraries such as tweepy, but all I need in this case is to list the messages in my inbox.
I've noticed that there is an account activity api which I can use to achieve this goal.
But, I do not understand how to implement Challenge-Response Checks, can you provide an example? how twitter checks this? it is through a post request to my site? to what specific URI they do this? I tried sending a pipedream url as webhook (to see what kind of request they were doing, but absolutely no request was shown)
The account activity endpoint is part of Twitter's Premium product - so you may need to pay to use it. They have comprehensive documentation on the CRC - that includes a sample Python implementation.
I think you will find it easier to use to use the GET direct_messages/events/list API call.
That will list all of the messages in your inbox for the last 30 days.

Facebook Messenger Bot: Not receiving POST request from FB

Weird thing is happening, I have registered my webhook and setup up everything, but now I am not receiving POST requests anymore when I am talking to my bot. FB only sends me GET requests to the webhook when I send a message.
Does anybody have an idea what the problem could be and how I can look for a solution?
Thanks in advance!
Re-authenticate your page.
curl -X POST "https://graph.facebook.com/v2.6/me/subscribed_apps?access_token=<ACCESS_TOKEN>
I was having the same issue and spent a lot of hours banging my head on the wall before I found this:
yii2 Webhook post empty
Not sure if its the same problem the OP had, but I think is usefull to leave it here anyway: the hook was being called with POST, not get, and the data was being sent, but PHP does not receives it on the $_POST, and so it looked like a GET (because Yii::$app->request->post() returns false). But then I logged $_SERVER and it was actually a POST request, except $_POST was empty. Then I found that answer
To retrieve the data facebook sends on PHP, you need either have to use
$data = file_get_contents("php://input")
or, if you use the Yii framework:
$data = json_decode(Yii::$app->request->getRawBody());

getting all notifications

I can easily get the unread notifications with this query:
https://graph.facebook.com/USER_ID/notifications?access_token=ACCESS_TOKEN
Is it possible to all the notifications (marked as read) too?
Yes, you can specify the parameter include_read as 1 to indicate you wish to receive read notifications.
https://graph.facebook.com/USER_ID/notifications?include_read=1&access_token=ACCESS_TOKEN
this link may be help you
http://developers.facebook.com/docs/howtos/notifications-api/
Using The API
Applications can generate notifications by issuing a HTTP POST request to the /user_id/notifications Graph API, with a app access_token.
POST /{recipient_userid}/notifications?access_token= … &template= … &href= …

Facebook graph api friend request sent

I need to use graph API to find out how many people have i sent friend request to and it is pending?
Is it possible to get this information using the API?
Using FQL: http://developers.facebook.com/docs/reference/fql/friend_request/