Hello everyone, first post form me.
I try to make an automation who is trigged when i have a new follower on Instagram.
Exemple: The number of followers increase from 70 to 71 (whawoo!) → switch on and off the light.
I figured out how to gate the number of followers and create a sensor (Thank napsio)
- platform: scrape resource: https://www.instagram.com/######/ name: instagram followers select: 'meta[name="description"]' attribute: content value_template: '{{ value.split(" ")[0] }}'
Ok now i have the sensor. So i try this:
- alias: 'instagram'
initial_state: False
trigger:
platform: template
value_template: '{{ states.sensor.instagram_followers | int + 1 }}'
action:
- service: scene.turn_on
entity_id: scene.flash_instagram
- delay: '00:00:03'
- service: light.turn_off
entity_id: light.neopixel_light
But it doesn’t work.
If someone can help me. thank by advance.