Home-AssistantConfig/script/tweet.yaml

31 lines
1011 B
YAML
Executable File

######################################################################################################
###Script to send notifications to Twitter as @BearStoneHA.
## Publish on Facebook as well - https://www.facebook.com/BearStoneHA/
## Enhancements by @dale3h
######################################################################################################
tweet_engine:
sequence:
- service: mqtt.publish
data_template:
topic: 'ifttt/message'
payload: >-
{{ tweet }}
retain: true
- service: notify.BearStoneHA
data_template:
message: >-
{{ tweet }} #IOT #SmartHome
# - service: ifttt.trigger
# data_template: {"event":"facebook_tweet", "value1":"{{ tweet }}", "value2":"{{ value2 }}", "value3":"{{ value3 }}"}
#
# - service: ifttt.trigger
# data_template:
# event: >-
# facebook_tweet
# value1: >
# {{states.sensor.ifttt_formatted_message.state}} #IOT #SmartHome