Facebook lost track of all links I have shared after migration - facebook

I have a website which I decided to migrate, but I haven't changed the URL's, yet the Facebook (https://developers.facebook.com/tools/debug/sharing/) complains that This URL hasn't been shared on Facebook before.
I shared more than 1000 posts more than one year, and now I need to re-scrape all the URL's to make it "shareable" again. I've read some sources where I've been told to put old URL as canonical, but the problem is, that the URL's are just the same as before.
Does anyone know, where's the problem, and how to solve it?

Okay, I've figured it out thanks to this:
https://gist.github.com/FrostyX/81d58222d1e835e24013
Basically it's just send a post request from the server to https://graph.facebook.com/ so the source is scraped once again.

Related

Can't seem to figure out what Facebook wants from me in regards of a redirect?

This seems to be something new that Facebook has recently updated over the past few months and I want the redirect to simply take users to the home page. I've already added https:// to all my redirects, so I think its some type of format error.
https://www.facebook.com/v2.12/dialog/oauth?client_id{{facebook_id}}&state=dd3925d67cf58016de9aa8874caf3135&response_type=code&sdk=php-sdk-5.6.2&redirect_uri=https%3A%2F%2Fhousesforsaleinmd.com%2Fmy-profile%2F&scope=email&ret=login&fbapp_pres=0&logger_id=ea17a674-1368-4015-afc3-3df73e4471ee&cbt=1586993724578&ext=1586996749&hash=AeZ0mz9F9GDwRi4S

Facebook saves my 404 Open Graph data (I use Varnish to cache)

I will try to explain this to see if anyone could have a clue. We cant figure out the problem since months and it is driving me crazy.
We have a site with a custom CMS developed. We use Varnish to cache articles. If you're not logged in, you should see the cached article by Varnish. If you're logged in, you should see the live article.
We have a feature to program the publishing of the article. So, maybe we write an article, and set to publish tomorrow at 9am. When is published, a cached version of the article is created by Varnish.
The problem is that after the article is published, Facebook (we dont understand why) is saving the 404 Open Graph data. It is like Facebook cant reach the cached article, or maybe is trying to access it before the cached version is created (maybe beacuse we added the Facebook Comments plugin and it is calling Facebook to retrieve the comments of the URL that is not still cached?)
I'm not sure if the problem is clear, but we are really lost and can't fix it. All the scheduling script is uselss if once the article is published, no one can share it on Facebook because it has the wrong Open Graph data (from the 404)

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.

Posting to a Facebook page from a .CFM file

Ok, I have been racking my brain over this, and I am digging myself deep into a hole of access tokens and cfhttp tags, so I need some help with this one.
My goal at the moment is simple (in words). I want the wall of my Facebook PAGE (not user) to reflect what is entered into a form on a .CFM file. Immediately I thought, oh, easy, I can just do an http post on submit. That worked fine. I used the access token I found on the Graph API Explorer and it posted to Facebook with no problem.
The problem is, the access token expires...
I realize that offline access is deprecated. So I went to the help page on Facebook for that, and now my problem is, pages dont have app_secrets, which is required to change the expiration time on an access_token. How can I continually renew my access token so that my .cfm page will constantly have access to my Facebook Page?
If you have an app, you have the sercet bit for it, just check the top of the app's settings. :)
You can read more about "The deprecated offline_access" here: https://developers.facebook.com/docs/offline-access-deprecation/

Retrieving friend's likes from the Facebook Graph API

Howdy- I have been tooling around with the Facebook Graph API and successfully retrieved back a list of my likes, and a list of my friends (once I authenticated using OAuth). But what I really want to achieve is pulling back my friend's likes. When I try and do that, obviously using the same URL that I use to pull back my own likes but subbing the friend's user id for "me", I don't get anything back, unless they have installed the app as well. Then I get them no problem. To be clear, I can only see the likes of friends who have installed my application. So clearly I am running into a security/rights issue of some sort.
I could see where this would be the case; you simply aren't allowed to see your friend's likes unless they have installed the same app. Fair enough, but then how is blekko.com doing it? I even tried using FQL without much luck. I suspect I am missing something totally obvious. Anyone had any luck with this? Maybe with the Javascript API or one of the other access methods? Thanks in advance for any guidance.
Your application needs the permission "friends_likes".
Check http://developers.facebook.com/docs/authentication/permissions for more info on the different permissions.
This SO answer might help if you're having trouble with the authentication / permission request process.