How to enable comments and likes for my posts made with my Facebook app? - facebook

When my Facebook app posts to the users stream those posts do not get links for Like and Comment. Other Facebook publishing apps, like Instagram, get these links.
I can't find it in my Facebook application's settings. Anyone knows how to do it?
(I think this is the same question as this one: Facebook : Like and Comment Functionality against Wall Post but I'm not sure.)
See Traroth's comment to get a more to the point description of what it is I'm asking about.

It seems Nathat Totten is right about how these links are defaults and that they are controlled by Facebook. There are three things that confuses this issue.
One is that Facebook Test Users behave a bit more special than you might think. Even when they are friends, they are not fully so. Making these default links turn up only for the user that posts them (for Test Users, mind you, I'm hoping it'll work all right for real users).
Another is the documentation for actions in the Facebook Graph API documentation for publishing Post objects:
A list of available actions on the post (including commenting, liking, and an optional app-specified action). read_stream. A list of JSON objects containing the 'name' and 'link'.
Which made me start to try find out how to include the commenting and liking links myself. I can't find this info anywhere, so maybe that changed without the above quoted documentation reflecting the change.
Anyway, if, indeed this is a Test User issue, then I don't need to do anything special to fix this. I'll try to remember to come back here when my (iPhone) app is ready for the real Facebook world and I get to see if it works in that environment or not.

Related

Sending requests to facebook as a user from a third-party app

I need to initiate searches on facebook marketplace from my application on the user's device. This needs to happen on the user's device, and as the facebook user associated with the user using the application, to avoid getting blocked by facebook. As far as I can understand, this cannot be achieved using facebook's OAuth login and accessing the facebook information that is accessible through it.
Another hypothetical way that comes to mind, is to use the token that the user uses to login into facebook itself, though this one sounds frankly illegal.
tl;dr is there a way to run a search and retrieve the results on facebook marketplace as a user on a user's device?
I found your question on SO, and spent a good bit of time researching this, as I wanted to know the answer myself. Unfortunately, as best as I can tell, this is not possible through any official APIs. It seems like they may have once had something like this, as I found several links to FB API documentation that looked promising. But, the links all rerouted back to the Graph API homepage. I found a couple of references to the big data breaches FB has suffered in the last couple of years as possible reasons why their APIs were retooled and locked down.
I found several Facebook developer posts with questions about a Marketplace API where there were either no answers after months or years, or an official Facebook moderator posting a response like "This is a great idea, we always want to improve, use this form to submit your idea" and so on with no follow up.
I also found at least one SO post within the last 18 months where someone in the comments claimed to be able to post products to FB, but I think this was related to the Business Page Product Catalog, and is not what you're looking for. This is more like if a car dealership or something wants to post a new car for sale that's tied to their FB business page.
The Graph API allows for some decent searching and edge traversal but it is all related to posts, pictures, feeds, etc., and nothing related to the marketplace. Facebook pushes their Marketing APIs so heavily that it was tough to filter through that noise. And, of course, all of marketing apis are geared toward creating ads.
I found some Facebook information around API URLs looking like https://graph.facebook.com/search=terms&type=some_type that was very promising. But the type options seem to be limited to adcountry, adeducationschool, adeducationmajor, adlocale, adworkemployer, adkeyword, adzipcode, adgeolocation, and audienceinterest. And, as I dug deeper, it appears this is related to finding targeting groups for creating targeted posts. Nothing for marketplace.
I think that the answer, unfortunately, is that there are no offical FB APIs at this time that will allow querying search results from the Facebook Marketplace, much less provide enough information to reproduce a listing to display on a 3rd party app.

How do I make sure someone likes my facebook page before entering contest?

I plan to start a Facebook contest where the user is first asked to like the page, then they submit their email to enter the contest.
I checked out other contest examples on:
http://contests.about.com/od/facebookcontests/tp/Facebook-Contests-and-Facebook-Sweepstakes.htm
Most Facebook pages direct a user to a "Like this page to continue" page. I tried to google around to find how this is done, but I cannot find anything. I tried to find ways to track specific user's likes,
For contest-specific legal reasons, I cannot use an app that makes the contest and keeps track of the entries. So I will need to create this from scratch.
I have made other apps before, and I do have access to an external server where I plan to create a page and link to it from facebook for the 'frame' type app.
Is there a standard way of doing this? Is there a documentation that I have yet to find?
Thanks
(Me answering my own question)
Some more googling I was able to find:
How to check if current facebook user like a page using PHP SDK?
A php version of the same question.
In that case, I will be able to check out FQL's documentation to find out how to get this information.
I really don't want a permission popup from facebook to pop up, and I don't think I will need that to make this work. I will try that and add a comment to this answer if it works just like what I'm looking for.

Facebook comments / permanent link

I had setup my website to use Facebook comments (using https://developers.facebook.com/docs/plugins/comments/) and was all working fine.
Unfortunately, my domain name expired and was snapped up by a domain parking company before I renewed it. I purchased a new domain name (the same, but .net instead of .com) and setup the website.
I have put in the same code as the previous site, and the comments do appear (because the old url is in the code), but on facebook profiles, the links are broken because they point to the old site (.com).
I can swap every .com for .net in the facebook code to get the links in Facebook working again, but this will mean I loose all my comments.
I would like to know if there is anyway of asking Facebook to move the comments associated with the old URLs to the new URLs, because I guess this is the only way of keeping my comments and making the links in facebook.com work (linking back to my new site).
Any info appreciated, I know this may not be a coding issue but it seems to be the best place to ask. I have seen similar posts, but they still have access to their old pages.
Many thanks!
As far as I know; You can retrieve the comments made on your old domain, but you will not be able to import them as regular facebook comments.
Instead, you can use a tool like disqus, to export the comments you retrieve from facebook.
To retrieve the comments, use one of the following methods:
1- Using facebook graph API
https://graph.facebook.com/comments/?ids={YOUR_OLD_DOMAIN_URL}
2- Using facebook FQL
Then, use this post to help you exporting the comments to disqus.
Hope this helps.

Weird Facebook API behavior, read group feed

I've got strange behavior when using the FB Graph API to read the feed of a group I am administrating. Everybody in this group is posting YouTube links and I wanted to write an App to crawl them all into a nice list.
But depending on the user who posted I get one of the following results:
a) type=video and everything is fine
b) type=status and I have to parse the link from the message instead of having a link field
c) type=status and the link is not even in the message
d) some users' postings are not in the feed at all
Does anybody know how to really obtain all message? I can see those posts including the links perfectly well using the Facebook web site...
Already tried to give each and every access right to my app, didn't help either.
I think I found the "problem": The result depends on the privacy settings of the user. Don't know why I can see the posts in the group but cannot automatically crawl it, only thing that happens now: I can't use the Facebook API but have to use some kind of HTML-parsing-crawler. Don't know why FB forces me to do that.

Find 'posts viewed by user' facebook graph api FQL

I am trying to build an algo which is quiet similar to edgerank algo of facebook. I am kind of missing 'edges' part, which is about user view anyone's post and hence creates an edge in this. Is there a way to get the posts user has viewed irrespective of user liked/commented on them. Apparently I believe this is somewhat not feasible after doing some research on graph/fql. But, did anyone of you came across anything like this?
No, there is no way, via an API or any other method open to developers, to see what posts the user has or has not seen. The only thing you could go by is likes, comments, and shares. That's it.