Crazy Facebook UI Dialog Error - facebook

So I cannot find any reason I am seeing the below behavior and if anybody has some insight it will be greatly appreciated.
Basically I am using the FB.UI from the JavaScript SDK to send a message to a user with a link. The link ends with a Guid, like http://www.domainname.com/register/33a1a0ae-e0fe-4eb6-9bf9-146d5492e3d6. This works sometimes, but occasionally fails with a generic 500 error from FB.
I have pulled out the HTTP POST request and have found a solution that I can recreate, unfortunately I cannot share the access code to allow SO users to actually run it (I replaced all sensitive parameters). Below are two identical requests that differ only in the Guid. The first succeeds every time and the second fails every time. I have numerous Guids that are doing this which makes if unreliable.
https://www.facebook.com/dialog/send?access_token=XXX&api_key=XXX&app_id=XXX&channel=http%3A%2F%2Fstatic.ak.facebook.com%2Fconnect%2Fxd_arbiter.php%3Fversion%3D5%23cb%3Df2cb8f5c1ca0402%26origin%3Dhttp%253A%252F%252Fwww.domainname.com%252Ff350c0fd55d5764%26domain%3Dwww.domainname.com%26relation%3Dparent.parent&channel_url=http%3A%2F%2Fstatic.ak.facebook.com%2Fconnect%2Fxd_arbiter.php%3Fversion%3D5%23cb%3Df11a615f3b71192%26origin%3Dhttp%253A%252F%252Fwww.domainname.com%252Ff350c0fd55d5764%26domain%3Dwww.domainname.com%26relation%3Dparent.parent&description=test&display=iframe&link=http%3A%2F%2Fwww.domainname.com%2Fregister%2F**33a1a0ae-e0fe-4eb6-9bf9-146d5492e3d6**&locale=en_US&name=test&next=http%3A%2F%2Fstatic.ak.facebook.com%2Fconnect%2Fxd_arbiter.php%3Fversion%3D5%23cb%3Df22e359d88321ce%26origin%3Dhttp%253A%252F%252Fwww.domainname.com%252Ff350c0fd55d5764%26domain%3Dwww.domainname.com%26relation%3Dparent%26frame%3Df33c13cd4ecc156%26result%3D%2522xxRESULTTOKENxx%2522&picture=http%3A%2F%2Fwww.domainname.com%2Fimg.gif&sdk=joey&to=XXX
https://www.facebook.com/dialog/send?access_token=XXX&api_key=XXX&app_id=XXX&channel=http%3A%2F%2Fstatic.ak.facebook.com%2Fconnect%2Fxd_arbiter.php%3Fversion%3D5%23cb%3Df2cb8f5c1ca0402%26origin%3Dhttp%253A%252F%252Fwww.domainname.com%252Ff350c0fd55d5764%26domain%3Dwww.domainname.com%26relation%3Dparent.parent&channel_url=http%3A%2F%2Fstatic.ak.facebook.com%2Fconnect%2Fxd_arbiter.php%3Fversion%3D5%23cb%3Df11a615f3b71192%26origin%3Dhttp%253A%252F%252Fwww.domainname.com%252Ff350c0fd55d5764%26domain%3Dwww.domainname.com%26relation%3Dparent.parent&description=test&display=iframe&link=http%3A%2F%2Fwww.domainname.com%2FFregister%2F**dd171262-dbcc-43c3-b9d1-e37dc53e3520**&locale=en_US&name=test&next=http%3A%2F%2Fstatic.ak.facebook.com%2Fconnect%2Fxd_arbiter.php%3Fversion%3D5%23cb%3Df22e359d88321ce%26origin%3Dhttp%253A%252F%252Fwww.domainname.com%252Ff350c0fd55d5764%26domain%3Dwww.domainname.com%26relation%3Dparent%26frame%3Df33c13cd4ecc156%26result%3D%2522xxRESULTTOKENxx%2522&picture=http%3A%2F%2Fwww.domainname.com%2Fimg.gif&sdk=joey&to=XXX

I tested both of these urls:
http://www.domainname.com/register/33a1a0ae-e0fe-4eb6-9bf9-146d5492e3d6
http://www.domainname.com/register/dd171262-dbcc-43c3-b9d1-e37dc53e3520
with the js sdk send method, and indeed the first url resulted in a 500 from facebook, while the first managed to send it.
I can't understand why the first UID triggers an error while the second does not.
The reason I kept asking for a working example of such urls is that when you share a url using facebook, they scrap that url (unless it's already in their cache) and extract meta data of that url so that a feed story can be composed.
Since the urls that I was trying are not accessible for facebook it might somehow trigger that error.
If I try this url:
http://laine.webhop.org/tresendas/register/33a1a0ae-e0fe-4eb6-9bf9-146d5492e3d6
then it works and I don't get the server error, even though it has the same UID as the first url I tried.
I suggest that you try to use urls accessible to facebook, if you still get errors for certain UIDs, then you should probably open a new bug report.

Related

Using m.me links with ref param

I'm trying to deeplink users into my facebook messenger bot, and I need to pass some data in at the same time. Supposedly this can be done by using m.me links, along with a query param.
My bot's page is https://www.facebook.com/Willy-1610141399078870/
The m.me url would be something like this. https://m.me/Willy-1610141399078870?ref=somedatagoeshere
The m.me link works to a degree on desktop, but the data isn't passed to the bot. I don't particularly need it to work on desktop.
However, when I try to open that link on ios or android, I get an error message.
Android
This user name doesn't exist. Try another code or link
iOS
Username was not found
The bot hasn't been published yet, so it won't be visible to anyone else. I need to be able to test this functionality before I publish, so I hope that's not what is causing the failure.
Has anyone else been able to use this feature?
It seems that the facebook-generated username can't be used for m.me links. It requires you to register an explicit username.
My page's generated name was Willy-1610141399078870, so https://m.me/Willy-1610141399078870 wasn't a valid url.
To register a username for your page, go to your page > About > Create Page #username.
Then, you can attempt to pick a username that isn't already taken. Somehow, #willy-the-test-page is already taken (?), so I got this incredibly confusing error message:
Taking the error message at face value, I decided to create another page and try again. This time, realizing that the message didn't mean what it said. Picking an available username clears the error message, and allows registration.
Just kidding! It will tell you again that the page isn't eligible.
The solution was to create a totally new page, and go through the #username creation flow again. It worked for me on the second attempt.
It's rumored that a page needs at least 25 likes to become eligible for an #username, but this isn't true in all cases.

Why does Object debugger say my URL is a facebook URL and isn't "scrapable"

In trying to create an "object" page for my first facebook app, I've run into some difficulty. I followed Facebook's Open Graph Tutorial nearly exactly.
After creating an "object" html page with the appropriate <meta property="og:... tags I tried running the URL through the Debugger Tool as suggested in the tutorial but I'm given the following error:
"Facebook URLs aren't scrapable by this Debugger. Try your own."
This page is in the same directory on my company's linux box as the canvas page, and is certainly not a "Facebook URL". If it matters, I'm using an IP instead of a domain name: xx.x.x.xxx/app/obj.html
...
I continued the tutorial anyway, but ultimately it does not seem to want to post a new action/object (is this even right?). I did however manage to get something to work, as in the app timeline view I apparently actioned one of those objects a couple hours ago. I assume this happened when I was pasting curl POST commands into the terminal.
I'm pretty new to the whole open graph, and facebook APIs, etc., so I'm probably operating under false assumptions of some sort, and I've been all over trying different things, but this error seems pretty bizarre to me and I can't seem to resolve it.
UPDATE
I just took the object page and put it on my own personal shared hosting acct. The debugger worked (inexplicably) fine on it, but I couldn't go too far since it's a different domain than the one authorized by my app.
Make sure og:url inside your html page does not point to facebook.
Also, make sure to look at the open graph protocol page (to see you formatted the og tags correctly.
Also, make sure the page is accessible to everyone, not just yourself.
Without knowing the URL it's hard to be sure, but it's most likely that your URL is either including a og:url tag pointing to a facebook.com address, or a HTTP 301/302 redirect to Facebook instead

Site URL blocked as "Spammy", but also no data was scraped in debug

Made a website for a client of mine who owns a small business. About three months ago, her site URL was blocked by Facebook for being "Spammy". We launched a pretty impressive "Go Here And Report It As Safe" campaign, but alas, it's not unblocked.
We made a new domain that mirrored the blocked one. This worked for about an hour. Then lo and behold! It got blocked too.
I was very curious, so I decided to try out the "Object Debugger". When I did, I got this message:
"Error Parsing URL: Error parsing input URL, no data was scraped."
I tried it again a few hours later, and it scraped just fine! Not only did it scrape and show up in debug perfectly, but it also didn't ping as blocked when I posted to my wall! It was amazing.
Sadly, I made an edit to the header file (just took away a meta tag), and now it won't scrape again. And it's blocked again.
The URL in question is enchantedcareers.com.
I feel like maybe the site isn't being blocked as spammy, but rather, there may be some kind of coding problem? Anyone else had an OG bug ping a URL as blocked upon link shim?
EDIT : Again, it let me post the link, with full preview and everything. I posted it, and about one minute later, the post was removed, and it was back to being "spammy"
The URL Debugger only scrapes my URL sporadically (with no page edits being made whatsoever).
I can't find a pattern.
no data was scraped: 9:06
successful scrape: 9:34
no data was scraped: 9:44
successful scrape: 10:04
no data was scraped: 10:08
Edit #2 : This is just completely crazy. Our new domain, enchantedcareers.net, which is nothing but my host's default quickstart.html page, is also blocked from being posted. When I try to post the .net domain, it gives me both the .net and .com domain as being blocked.
THE .COM DOMAIN ISN'T EVEN TIED TO THE .NET NAME. This domain is straight out of the box. Why is it bringing that domain up when I try to post a new one?
I'm just so confused.
It won't scrape the .net name, either.
Could this be a server thing...?
Your URI comes up clean on a URIBL check, you're on Dream Host, which is typically reliable, so I wouldn't expect to see your IP address show up in an DNSBL check. I don't see any glaring errors in your page code that typically causes the Facebook parser to choke.
There is one "suspicious" script on your page according to this report. Try removing this, clear your cache and see if Facebook will parse your URL.

Caching OG data in the debugger, forcing og:type website, and authorization popup for "See exactly what our scraper sees for your URL" woes

Having issues getting Timeline to work. It is a two part problem.
First, there is an issue of caching parts of the OG metatags. When the debugger goes to my URL, I know it is hitting it correctly because the og:url it spits back is correct which means it has been processed on my end (ex: I send it to og.php?og=read&chapter=799, and it will spit back the right book_id for the og:url, meaning my script processed it). But all the other information seems to be cached. I originally and erroneously had an fb:app_id and og:site_url for an object, so I removed those. The output still shows those as having an existing site_url which is throwing an error. Having a fb:app_id forces the og:type of 'website', which I have set (correctly) to my namespace and object. When I try to POST the action, I get an oAuthException error back, that an og:type of 'website' isn't valid for an object. Once again, that should be fixed, but it keeps caching the old OG data. I have tried adding ?fbrefresh=1, but that did nothing.
Another issue, possibly related...even though I know it got there, and my script processed the request, Facebook doesn't report that. When I click on "See exactly what our scraper sees for your URL" it shows the authentication URL (see below)! As though, it never got there and the popup was initiated, which isn't even how the code for og.php works!! My guess is they got that from the base domain name itself (exmaple.com) before trying the full request with example.com/og.php.
window.parent.location='https://www.facebook.com/dialog/oauth?client_id=164431733642252&redirect_uri=http%3A%2F%2Fapps.facebook.com%2Fexample%2F%3Fpage%3D&state=064bd26ff582a9ec7c96729e6b69bbd2&canvas=1&fbconnect=0&scope=email%2Cpublish_stream%2Cpublish_actions%2C';
I figured it out. I thought the og:url was the URL you wanted people to use to get to the correct page in your app, like an action link. It is, but it isn't. I now have it match the OBJECT_URL you send to timeline.
I had a different URL (an action link to the app), which when redirected, can't be reached by the crawler because it is inside the applications authorized wall. This caused the og:type of website, and data to appear cached.
To fix it, the object_url I post to timeline, and the og:url in the metatag is the same. But you can figure out if it is the crawler or the action link by looking for the query string: ?fb_action_ids=SOME_ID which is sent from link on the timeline. If it contains that, then I forward it to the application page needed from there.
I'm having similar problems to you. It kept complaining about og:site_url being set, even though I never set those. It appears that the error messages it sends are actually inaccurate, and the problem is not that og:site_url is being set, but that the og:url is different from the object url. Sometimes a wrong error message is worse than no error message!
A further question is why an object url has to correspond to a live page that a user will see. An object is a logical unit, but it doesn't necessarily correspond to a single user-visible page. Your redirection trick might work, but it is not the proper way to do something. When I post an action related to an obect, the object url should be used to draw the information of the object, but I should be able to send the user somewhere else. If this was an intended design I think it is a mistake.

Facebook Send Dialog fails to send links to Facebook itself -- why?

I'm trying to use Facebook Send Dialog in a WinForms frame with a browser control and direct URI (you can repro just by clicking the links below). It works fine with link=http://www.foo.com, sending the message properly if you enter a message and click "Send":
http://www.facebook.com/dialog/send?app_id=179873125388138&link=http://www.foo.com&redirect_uri=http://jonnewman.com/&display=popup&to=100002395463043
However, this fails with link=http://www.facebook.com or any path under it. Clicking "Send" just gets you "Sorry, something went wrong. We're working on getting this fixed as soon as we can.":
http://www.facebook.com/dialog/send?app_id=179873125388138&link=http://www.facebook.com&redirect_uri=http://jonnewman.com/&display=popup&to=100002395463043
The aim is to write a script to make it easier to send messages asking all users in a particular group to a page (prepopulating the recipient list). Since Facebook has restricted groups larger than 500 members, our organization has to move to a Facebook Page, and I want the Send Dialog to link the new Facebook Page. Why won't this work? Is there a workaround? Are there other criteria for what links Send Dialog will and won't send?
Also, is there a way I can determine whether the send occurred or not, for example an event to catch? Whether you send or cancel, the Navigated event is still redirect_uri/#_=_.
Once I have Send Dialog working, I will add Show-FBSendDialog to Facebook PowerShell Module, which already has numerous capabilities to automate Facebook from PowerShell.
ran some tests and it seems it is blocking any fb domain http://on.fb.me/91S2P8, sometimes this is temporary otherwise need to rethink...
I see your second link isn't working... but if you add your company page id or name to link it should work. following link works for me:
https://www.facebook.com/dialog/send?app_id=179873125388138&link=http://www.facebook.com/Intel&redirect_uri=http%3A%2F%2Fjonnewman.com%2F&display=popup&to=100002395463043
hope this helps
I got solution. I also had same problem. No post helped me. Solving error for 2 days.
There were posibility of two mistakes(that was done by me).
Link Parameter given in url should be working. I have linked to api namespace but not given SSL url. So it was giving problem. You can given your web site address.
And redirect_uri parameter should be working. Try to give redirect_uri to same page most probably.