Facebook Graph API - Batch App-to-User Notifications Becoming Lost - facebook

My Facebook app will send app-to-user notifications when certain events trigger. It works flawlessly most of the time.
The exception is if TWO notifications are triggered and sent to the same user at the same time. It's an uncommon scenario but what sometimes happens is this: only one notification preview appears on the bottom left and the other notification shows in the notifications dropdown. After a few seconds pass the preview disappears yet only one notification remains in the dropdown. One notification is now lost.
My API requests are done in batch and the results show success.
Again, this only happens occasionally - which is the part that confuses me most. I am having trouble debugging the issue because I see no signs of error on my end.
My best guess is that since the batch requests are for the same user at the same time, Facebook is somehow confusing or overwriting one. It seems odd, however, that both are shown inside facebook for a brief period (one in corner preview and the other in the dropdown) and then one is lost.
Has anyone seen this before? Any ideas or suggestions on how to troubleshoot this?
Thank you!

Related

When does Facebook Page Conversation webhook is triggered?

Does anyone know when Facebook triggers this webhook?
https://developers.facebook.com/docs/graph-api/webhooks/reference/page/#conversations
I suppose to get thread id from this webhook, but seem that it never triggered no matter how I change the conversation (e.g make new conversation, change flags,...)
Turned out that it takes quite long time before it starting to send conversation callback. It works OK now.

Intercom welcome msg pop ups multiple times

I am integrating Intercom into my website,which pop ups a welcome message for all new users. but the problem is the message pops up again and again ,every time i call intercoms update method with user json as parameter until i refresh the window. this happens only when user is logged in first time.
Anybody knows how I can limit the welcome message to display only once for a user.
Micheál here from the support team at Intercom.
Intercom will only deliver a given message to a user once so if you see a situation where the same message is being sent multiple times, it's likely something is interfering with the cookie we create.
This most commonly happens when using a domain with a public suffix e.g. my_awesome_website.herokuapp.com or similar.
If you're still having issues please drop us a line at team#intercom.io and we can investigate further 🙂 

Facebook Leadgen does not send Webhook Request

I've an app which collects leads generated using Facebook Leadgen Ad.
I've a Webhook subscribed for that but for some reason it never sends any requests when leadgen form is filled.
Earlier it was working without any issues.
I noticed yesterday that I received request an hour after forms were filled whereas today I've not received any requests but I do see new leads in the CSV file I downloaded.
Will appreciate if somebody can point me to what can be going wrong here.
Thanks in advance!
Not sure if you have come across this but, there is a testing tool which you can use to submit test leads for a page and see if the lead is getting pushed to your app successfully or not -
https://developers.facebook.com/tools/lead-ads-testing?__mref=message_bubble
If you click on the Track Status button after creating test lead it tell you the status of the webhook ping for the submitted lead.

How to execute a facebook notification after a certain amount of time?

I am new to Facebook development and I am wondering how I can delay execution of an app notification by a given amount of time (days)?
At https://developers.facebook.com/docs/games/notifications or via Google I can't find anything regarding delaying notifications, everything seems to happen immediately.
What I am trying to achieve is that when a facebook app is loaded, I will add a notification to be executed in x days so that the user is reminded of returning to the app then.
I will do this every time the app loads, overwriting the existing notification that was still to be executed.
By that, the user will get the notification only when he really is not logged in for x days.
I'd like to solve that through Facebook alone and not through timers on the server. Can it be done?
There is no way to send delayed notifications, you need to do that on your own. For example, with a Cron Job that checks for the timestamp of the last login every day. Creating a new delayed notification (and deleting the old one) whenever the user logs in would be a weird solution anyway...Those things are usually done with Cron Jobs, there is no need to use the Facebook API when you don´t need it.

Facebook APP alerts - The same thing as app requests?

I've used 'Are You Interested', a Facebook APP and when something on that app happens (such as a user sends me a message in that app) then I will see (to the left under APPS) a numeric value representing the number of new events that have happened on 'Are You Interested' since I last looked.
I want to do the same thing with my App, as it's also a niche dating site. I'd like to notify users when someone sends them a message or views their profile. I was told that I should search for app requests. However the code samples that I see seem to be slightly different than what I want to accomplish.
The information I am finding seems as though it is intended for me to allow my users to request things from their friends. That's completely different than what I want to do. There's no need for them to request anything from friends.
When I tried sending one to my test account, just to see what happens..it incremented the numeric value to the left under APPS by 1, which is a good thing, but the text was so generic, it was something like, "So and so is requesting something in [sitename]", but I don't want it to say that and I didn't see anywhere to change this text....furthermore, it added a 'Notification' to the very top of Facebook with the same generic request message. Again, that's not what I'm looking for. When I receive these APP Alerts for other apps, they don't add a 'Notification' up top of Facebook, and I don't want to either. I do believe that the code snippets I found under 'Requests' is something different than what I'm looking to achieve.
Just to summarize: I have a dating app, and people can send messages to eachother. I want an APP Alert (as I'm referring to it) to be seen to the left under Apps and also to the right in the bookmarks area, but I want the message to not be so generic and I don't want users to be selecting friends to request something. I want this action to come from my server and sent to the user that will be receiving the alert. I also do not want a facebook 'Notification' up top each time they receive a message. I hope I'm being clear in what I'm trying to accomplish. Thanks in advance for any guidance. -Chris