How to programatically in Handover Protocol mark message as read/done in inbox of facebook messenger? - facebook

Handover Protocol of Facebook messenger seems to have changed recently. Lot of online materials I have seen refer to primary and secondary receiver but the docs https://developers.facebook.com/docs/messenger-platform/handover-protocol/ does not mention it now.
This is how my Advanced messaging menu looks like.
Advanced messaging
I am developing external chatbot integration and want message primarily to be replied by chatbot and mark it as read/done in messenger inbox. If bot does not know the response, I want to keep it (mark it) unread in inbox to drag attention of human operator.
Still all messages from 3rd person and also replies from bot are shown as Bold (unread) in messenger inbox. What is the correct approach to achieve this?

Related

How work with Facebook Page Subscription Messaging

I'm working on Facebook Messenger chatbot and I've found documentation about Facebook Page Subscription Messaging. This feature allow your bot to send messages to users, outside of the "stardard" 24 hours messaging.
Facebook's documentation explains what is Subscription Messaging
but I've not found more details about how implement it.
My questions:
Is there any back-office to be able to send this kind of message ? For example to allow a Community Manager to send this messages
In the case where to do code is mandatory, I suppose I have to build a Facebook's users list and use it to send "Subscription Message" type to each. Can I send these messages to these users at the same time or I have to do some packets or add a small timeout between each messages ?
What happends if I send a "Subscribe Message" to an user who have unsubscribed to my bot's messages ?
Thanks !

Facebook won't send notifications from messages sent by a user that was transferred from a bot to the facebook page inbox by the Handover Protocol

I will name my firstborn after whoever answers my question!
My bot uses the Handover Protocol to transfer users from the bot (primary receiver) to the page's inbox (secondary receiver) after they tap on a 'chat with human' button, the problem is that I'm not getting any facebook notifications when the user starts messaging a human (page inbox).
Right now I'm having the bot email me anytime it transfers a user to a human but this fix obviously doesn't scale, ideally I would want facebook to send me notifications on my phone just like it does by default to pages that receive messages and don't have any bots installed.
I know I can see the messages sent to a human by using the 'standby' webhook but those are developer-side server logs, what I want are normal facebook notifications sent to the page owner and the people in the page's Roles so they reply to those messages instead of me (the developer) being the only one being notified through emails I have to send myself.
1.You have to go to Your Page--> Settings--> Notifications--> Select this option
from Messages- "Get a notification each time your Page receives a message".
2.Download "Facebook Pages Manager" App to get all your page related notification
on your phone.

Redirect all Skype Messages from one profile to another

As the title says, is there a way to redirect all skype messages I receive
from one profile to another ? The Skype support states that you can activate
SMS messages which will get redirected but I just want simple chat messages
to be redirected from one profile to another automatically.
Just to clarify, both profiles will be online and not one offline and the other
online.
All code/forums/books will be appreciated.
There is commercial tool for this. It works across many messengers but the monthly cost is quite big: https://sameroom.io
Also here is the most relevant discussion of the stuff: https://github.com/microsoft/botframework-sdk/issues/4046
Skype doesn't support incoming text messages - you can set up an SMS ID which allows you to send SMS messages from Skype and receive the answer to your mobile phone.
To do this, go to Skype -> Preferences -> Messaging. After you have validated your mobile number, all SMS messages you send from Skype will display your mobile number as the sender ID.

Does Facebook Chat XMPP support XEP-0184 Extension?

From last two days, I have been trying to find out why the hell, Facebook is not sending the message receipts. (same like "Seen" feature in Web Interface).
This is XMPPMessage I am sending to Facebook Chat XMPP Server. But Facebook is in no mood to return the receipt or acknowledgement of the message. If you can guys can guide me, it will be really helpful.
<message type="chat" to="-XXXXXXXXX#chat.facebook.com" id="E32DB9A2-8D0F-4BEC-87DF-299102CC4ABF"><body>Helll</body><active xmlns="http://jabber.org/protocol/chatstates"/><request xmlns="urn:xmpp:receipts"/></message>

Facebook Chat, XMPP, Setting presence?

When changing the presence in Browser (offline/online) in Facebook Chat, the chat system sends the XMPP message in form:
<presence to="-myidhere#chat.facebook.com/adfskjfskjdfh" from="-otheridhere#chat.facebook.com" type="unavailable">
When I send my own presence from non-browser side (xmpp client) to the browser side with exactly same syntax, it seem not to effect. What I am missing here ?
Thanks a lot,
-Mika
It seems like you can't do that with the facebook xmpp implementation, as they write in the documentation:
Facebook Chat should be compatible with every XMPP client, but is not
a full XMPP server. It should be thought of as a proxy into the world
of Facebook Chat on www.facebook.com. As a result, it has several
behaviors that differ slightly from what you would expect from a
traditional XMPP service
There's an open bug on this matter: XMPP: can't change availability, and also this thread also talks about it: Xmpp chat invisible presence.
Also, don't expect the fb apis to have the same functionality as you get using the fb webpage.
They obviously don't open everything they have to the apis.