Making Facebook messenger notify more usable

I’m able to send image from an url with the following curl command. Still looking for a way with local files:

curl -X POST -H “Content-Type: application/json” -d ‘{
“recipient”:{
“phone_number”: “00XXXXXXXXX”
},
“message”:{
“attachment”:{
“type”:“image”,
“payload”:{
“url”:“https://home-assistant.io/images/supported_brands/nest.png”,
“is_reusable”:true
}
}
}
}’ “https://graph.facebook.com/v2.6/me/messages?access_token=THESUPERLONGTOKENKEY

Hm, thats awesome, i will test that. No problem for me, ill just create a script that puts the image on my webserver. Thanks :slight_smile:

Edit; still does not work for me. I get this error:
{“error”:{“message”:"(#100) Upload attachment failure",“type”:“OAuthException”,“code”:100,“error_subcode”:2018047,“fbtrace_id”:"***********"}}

Has anyone got a working script now? Please share. I’m struggling getting a screenshot via Facebook notify…

Hi all,
I am looking for a way to send FB Messenger notifications to “ALL” users who interacted with the FB chat component… Is it possible to do? IF so, how?

The current FB component only allows to send messages to a list of phone numbers , which I have working perfectly. I have a large group of kitesurfers here, who want to receive wind alerts… I manually added a couple of people to my HA config file, but I do not wish to spend my days managing phone numbers and would love to be able to send notifications to anybody who ever interacted with a chat component on the page I created.
Any advice on how to achieve that? That would require FB to know the numbers of people without me having to collect them.

Also, it is not seem possible to push those notifications to FB groups? only pages can seem do these notifications.

I just implemented FB messenger “broadcast” functionality. Now no need to collect phone numbers of people.
it will push notification to ALL people who interacted with the bot and keep the chat with the bot open.
Works like a charm on my haas.io install.

My pull request to home assistant here:
https://github.com/home-assistant/home-assistant/pull/12459

Hello,

Nice job, is that possible to have multiple targets ?

Chears.

I’m also looking for a automation script of how to send image from local file
Hope someone can point me in the right direction.