Skip to content

Commit 55f99ee

Browse files
gopalkildoliyafabaff
authored andcommitted
Notify component for Facebook Messenger (home-assistant#1683)
* Create notify.facebook.markdown * Update notify.facebook.markdown * Update notify.facebook.markdown * Added Facebook logo
1 parent 492f975 commit 55f99ee

File tree

2 files changed

+51
-0
lines changed

2 files changed

+51
-0
lines changed
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
---
2+
layout: page
3+
title: "Facebook Messenger"
4+
description: "Instructions how to add user notifications to Home Assistant."
5+
date: 2016-12-31 14:14
6+
sidebar: true
7+
comments: false
8+
sharing: true
9+
footer: true
10+
logo: facebook.png
11+
ha_category: Notifications
12+
ha_release: "0.35"
13+
---
14+
15+
The `facebook` notification platform enables sending notifications via Facebook Messenger, powered by [Facebook](https://facebook.com).
16+
17+
To use this notification platform in your installation, add the following to your `configuration.yaml` file:
18+
19+
```yaml
20+
# Example configuration.yaml entry
21+
notify:
22+
- name: NOTIFIER_NAME
23+
platform: facebook
24+
page_access_token: FACEBOOK_PAGE_ACCESS_TOKEN
25+
```
26+
27+
Configuration variables:
28+
29+
- **page_access_token** (*Required*): Access token for your facebook page. Checkout [Facebook Messenger Platform](https://developers.facebook.com/docs/messenger-platform/guides/setup) for more information.
30+
- **name** (*Optional*): Setting the optional parameter `name` allows multiple notifiers to be created. The default value is `notify`. The notifier will bind to the service `notify.NOTIFIER_NAME`.
31+
32+
### Usage
33+
34+
With Facebook notify service, you can send your notifications to your facebook messenger with help of your facebook page. You have to create a [Facebook Page and App](https://developers.facebook.com/docs/messenger-platform/guides/quick-start) for this service. You can control it by calling the notify service [as described here](/components/notify/). It will send a message on messenger to user specified by **target** on behalf of your page. See the [quick start](https://developers.facebook.com/docs/messenger-platform/guides/quick-start) guide for more information.
35+
The phone number used in **target** should be registered with facebook messenger. Phone number of the recipient should be in +1(212)555-2368 format. If your app is not approved by facebook then the recipient should by either admin, developer or tester for your facebook app. [More...](https://developers.facebook.com/docs/messenger-platform/send-api-reference#phone_number)
36+
37+
```yaml
38+
# Example automation notification entry
39+
automation:
40+
- alias: Evening Greeting
41+
trigger:
42+
platform: sun
43+
event: sunset
44+
action:
45+
service: notify.facebook
46+
data:
47+
message: 'Good Evening'
48+
target:
49+
- +919413017584
50+
- +919784516314
51+
```
12.4 KB
Loading

0 commit comments

Comments
 (0)