How to accept new requests using Facebook graph API - facebook

How to accept new requests using Facebook graph API? If it is possible without using graph API, then also it will work for me. I have searched a lot regarding accepting or denying new requests in facebook, but did not find something useful.
Please give me some insight in this matter.

Accepting requests is only possible via interface provided by Facebook and not programmatically.
While you can remove requests via Graph API it's not the same as accept/rejection of request.
Remember requests mechanism is a communication channel, not another API to consume on application level.

Related

Connect App Flutter with API instagrame Publish comment

I have a question about connecting my app, made with Flutter, with the Instagram API.
I want the user to register with their account, store the access token and then send a post to the API to publish a comment or add a like.
Can I do this with Flutter or do I need to use a different language like Python?
I checked the API documentation that Instagram provides and it seems that you can only do read-only requests (liking a post might not be possible).
The API you mentioned in your tags will not work with personal accounts, as Instagram states:
The API cannot access Instagram consumer accounts (i.e., non-Business or non-Creator Instagram accounts). If you are building an app for consumer users, use the Instagram Basic Display API instead.
You can try to use the mentioned Basic Display API instead, but mind you won't be able to author any posts or do actions in behalf of the user. To circumvent this, you might have to reverse-engineer the frontend facing portion of Instagram but I won't go into that.
To come back to your question, Flutter is well able to send network requests as mentioned here, but you still have a long way until you have functioning access to Instagram (check the Getting Started).

Facebook Restful API create reaction

I'm looking to create a facebook reaction (like/etc) using just the authenticated user token and a URL without using the SDK. I keep reading that the API is RESTful, however, I can't get any information on this aspect of it. From this API reference link
https://developers.facebook.com/docs/graph-api/reference/v2.7/object/likes/
it seems I can post a "like", but I don't see any information anywhere about the full spectrum of reactions (sad/angry/etc). The docs say that if a reaction has already been given by the user than posting a like won't change it - but it doesn't indicate how I would post a reaction other than "like". Simply put, my questions are: is it possible and if so, how?
I believe this is not currently exposed
https://developers.facebook.com/docs/graph-api/reference/post/reactions
Creating
You can't perform this operation on this endpoint.

How to simulate silent login to Facebook Graph API?

I'm working on an API that will aggregate data from several website, including facebook. The API has an engine that harvests data on regular intervals, and then the client app polls the API to get the data from all websites centrally.
The problem is that the API has no way of authenticating on the regular, behind-the-scenes harvests, as Facebook insists that the user has to click on the OAuth Dialog. With the short story being that there is no way to login to graph API silently this almost means that developing such an API is not possible (except for harvesting only public data).
However, I'm not easily satisfied by "it's not possible" answers and my clients - even less so. Accessing private information on demmand is defnitely possible as Facebook apps do that. For example, the official Twitter app posts on my wall whenever I tweet. I guess apps only need a permission once and then can access the user's profile as much as they like.
So this leads me to think that I should do a combination of a Graph API client and an application that talk to each other, and whenever the API needs to harvest - it asks the app to get the data and fetch it to the API. Or maybe it should be a push model (the app sends the data whenever it's generated) rather than pull (the API requests the data at regular intervals).
Am I on the right track? Is any of these the correct design approach?
I did some searching but it's very hard to find any useful discussion on the topic as whatever keywords I try I only find "Can I login silently? No" type of discussions.
You'll want to look into the offline_access permission. This lets you access a user's data when they don't have an active session, or are offline. That's as close to "silent login" as you can get.

How do I publish an activity on facebook using the Graph API

The old Facebook Legacy REST API had a function dashboard.publishActivity, however the new Graph API only allows messages to be posted on /me/feed.
Is there a way to send activities using the Graph API?
As mentioned in http://developers.facebook.com/blog/post/552/ Facebook "have removed the section which displayed the News that developers published via the Dashboard APIs in the Games Dashboard". Therefore the dashboard.publishActivity function no longer provides any useful functionality. My recommendation is to switch to either using stream posts or to Requests 2.0, as these will provide the same sort of distribution that you're looking for.

Using both Facebook Graph API and Old Rest API? Please help!

I am developing a Facebook application that will use Facebook events.
I want to be able to create and edit event as well as invite users friends to the event.
I prefer to use the new Graph API to handle all connections with Facebook and I many ways I am able too, but, the Graph API cannot send invites.
I saw that the Old Rest API got far more ways to interact with Facebook so I tried to use both systems on the same time but when I send the Access token that I have created with the Graph API a long with a call to the old API it says "Invalid OAuth 2.0 Access Token".
My question is, is there a way to convert the new Graph API access token to be used with the old rest API? Is there perhaps another way to get both systems to work in the same application?
Please help! All input are welcome.
I´d recommend against the old REST api. Support will be canceled sooner or later and then you will have to port to graph api anyway.
To send invites to your app you can use fbml/xfbml. try the http://developers.facebook.com/docs/reference/fbml/multi-friend-selector togehter with the JavaScript SDK as described here: http://www.takwing.idv.hk/tech/fb_dev/jssdk/learning_jssdk_11.html
good luck!