facebook messenger api context - facebook

I am playing with facebook messenger API
I wonder if there is a way to maintain context of the conversation. Maybe some kind of sequence order, or payload after messages.
Thank you.

Messages include a mid you can use:
https://developers.facebook.com/docs/graph-api/reference/v2.11/message

Related

Facebook Chatbot delete messages by id

does anybody know if it is possible to delete messages by id.
For example I have an update for my content so that the user must not see any outdated messages. Didn't find anything in the graph API...
Message docs
thx
franzus
Facebook does not allow you to delete messages using the Messenger API, or the Graph API
I am not aware or, nor have found documentation for, a method that does DELETE operations (or UPDATE for that matter) on a FB Message.
The Messenger Docs provide methods for sending messsages, subscribing a page to your application's webhook, retrieving user profile information, and setting various options for your bot.

Is there a way to send a conversion event to Facebook using their API?

I'm working on a SaaS service. There are certain events that happen on the backend which I'd like to use as conversions for Facebook Ads. I figured out there's a way to send a custom event using the Facebook js-pixel. I can't use JS for the events I'd like to track. Maybe it's possible to use something like a good old-fashioned cURL?
Thanks!
Yes, there is the
Offline Conversions API
With Facebook's Offline Conversions API you can send your offline conversion events using an offline event API. You can see how many of your customers viewed or clicked on Facebook ads before converting offline.
https://developers.facebook.com/docs/marketing-apis/offline-conversions/v2.8

Any webhook or way to get notification if somebody sends message to Facebook Page?

I'd like to get a notification when somebody messages my Facebook Page (business). Is there any way to do this?
I see some webhooks Facebook supports at https://developers.facebook.com/docs/graph-api/webhooks but I don't see one that looks that I can use for this.
The "conversations" object may be what you want. You can either use webhooks with that object (preferred way) or you can use a cron job to check for new conversations once in a while.

Can I use some API call to invite User's Friends?

I want to invite facebook friends to my app. via some sort of API call whether rest or PHP Sdk, so is there a way to do so. I know about multifriend selector in FBML but don't want that. Please tell that which API can be used to do so? Graph API or any other? I am using PHP so if you know some PHP API call then that is also good.
thanks in advance for assisting me.
You can use the Requests Dialog for invites. This will prompt the user for which friends to send a request/invite to. This is designed to work in iframe apps, no fbml required.
http://developers.facebook.com/docs/reference/dialogs/requests/

Send Message API for SoundCloud

Does the SoundCloud API allow messages to be sent to other users ? I looked through the docs and didn't find any action APIs.
No, it does not, as you can read here