Iam using this Automation Blueprint as base but take controll over it by myself
Blueprint Multiple Notify Agent Calendar Agenda
This is my Automation (i use a simlar one for my wife too
alias: Multi Calendar AI Andre
description: ""
triggers:
- at: "06:00:00"
trigger: time
actions:
- variables:
weather_entity: weather.home
calendar_number: three
calendar_entity_1: calendar.andre_s_kalender
calendar_entity_2: calendar.familie
calendar_entity_3: calendar.feiertage_nrw
notify_number: one
zone_entity: zone.home
calendar_duration:
hours: 18
prompt: |2
Bitte generiere einen Text für eine Benachrichtigung, die an die Benutzer mit Smartphone gesendet wird
mit hilfreichen Informationen.
Du bist ein hilfreicher persönlicher Agent, der Text für den Benutzer generiert:
- Deine Antworten sind hilfreich, freundlich, warmherzig und aufschlussreich.
- Deine Antworten sind nicht technischer Natur und enthalten keine internen Details von Home Assistant, wie z. B. Entitäten in den Antworten.
- Deine Nachrichten helfen dem Benutzer, sich auf seinen Tag vorzubereiten, zum Beispiel:
- Notieren Sie sich ungewöhnliches Wetter für den Ort und die Jahreszeit (aber keine alltäglichen Details wie „0 % Niederschlagswahrscheinlichkeit“).
- Wie viel Zeit bleibt bis zu ihrem ersten Treffen?
- Alles, was besonders oder einzigartig sein könnte, wie zum Beispiel die Feier eines Geburtstages, Jahrestags
- Wenn am nächsten Tag ein Feiertag auf einem Werktag (Montag - Freitag) ist informiere den User daüber.
- alias: Fetch First Calendar Agenda
data:
duration:
hours: 18
target:
entity_id: calendar.andre_s_kalender
response_variable: agenda_1
action: calendar.get_events
- if:
- condition: template
value_template: "{{ (calendar_number == 'two') or (calendar_number == 'three') }}"
then:
- alias: Fetch Second Calendar Agenda
data:
duration:
hours: 18
target:
entity_id: calendar.familie
response_variable: agenda_2
action: calendar.get_events
- if:
- condition: template
value_template: "{{ calendar_number == 'three'}}"
then:
- alias: Fetch Third Calendar Agenda
data:
duration:
hours: 18
target:
entity_id: calendar.familie
response_variable: agenda_3
action: calendar.get_events
- alias: Fetch Weather Forecast
data:
type: daily
target:
entity_id:
- "{{ weather_entity }}"
response_variable: daily_forecast
action: weather.get_forecasts
- variables:
forecast_entity: "{{ daily_forecast[weather_entity] }}"
forecast: "{{ forecast_entity.forecast[0] }}"
- alias: Conversation Agent Notification Text
data:
text: >-
Time: {{ now().strftime("%A %B %d %H:%M %p") }}
{%- if zone_entity is defined %}
Latitude: {{ state_attr(zone_entity, 'latitude') | round(1) }}
Longitude: {{ state_attr(zone_entity, 'longitude') | round(1) }}
{% endif %}
{%- if weather_entity is defined %}
{%- set temperature_unit = state_attr(weather_entity,
'temperature_unit') -%}
Forecast: {{ forecast.condition }} ({{ forecast.temperature }}{{
temperature_unit }}, {{ forecast.precipitation }}% precipitation)
{%- endif %}
Calendar "{{ state_attr(calendar_entity_1, 'friendly_name') }}" events
for the next {{ calendar_duration.hours }} hours:
{%- set agenda = (agenda_1 | items | first)[1] %}
{%- if agenda.events %}
{%- for event in agenda.events %}
- Summary: {{ event.summary }}
Start-End: {% if event.start is defined %}{{ event.start }} to {{ event.end }}{% else %}All Day{% endif %}
{%- if event.description is defined %}
Description: {{ event.description }}
{% endif -%}
{%- if event.location is defined %}
Location: {{ event.location }}
{% endif -%}
{%- endfor %}
{%- else %}
- No upcoming events.
{%- endif %}
{%- if (calendar_number == "two") or (calendar_number == "three") %}
Calendar "{{ state_attr(calendar_entity_2, 'friendly_name') }}" events
for the next {{ calendar_duration.hours }} hours:
{%- set agenda = (agenda_2 | items | first)[1] %}
{%- if agenda.events %}
{%- for event in agenda.events %}
- Summary: {{ event.summary }}
Start-End: {% if event.start is defined %}{{ event.start }} to {{ event.end }}{% else %}All Day{% endif %}
{%- if event.description is defined %}
Description: {{ event.description }}
{% endif -%}
{%- if event.location is defined %}
Location: {{ event.location }}
{% endif -%}
{%- endfor %}
{%- else %}
- No upcoming events.
{%- endif %}
{%- endif %}
{%- if (calendar_number == "three") %}
Calendar "{{ state_attr(calendar_entity_3, 'friendly_name') }}" events
for the next {{ calendar_duration.hours }} hours:
{%- set agenda = (agenda_3 | items | first)[1] %}
{%- if agenda.events %}
{%- for event in agenda.events %}
- Summary: {{ event.summary }}
Start-End: {% if event.start is defined %}{{ event.start }} to {{ event.end }}{% else %}All Day{% endif %}
{%- if event.description is defined %}
Description: {{ event.description }}
{% endif -%}
{%- if event.location is defined %}
Location: {{ event.location }}
{% endif -%}
{%- endfor %}
{%- else %}
- No upcoming events.
{%- endif %}
{%- endif %}
{{ prompt }}
agent_id: conversation.openai_conversation
response_variable: agent
action: conversation.process
- alias: Send notification
data:
title: Tagesplanung für den {{ now().strftime('%d.%m.%Y') }}
message: "{{ agent.response.speech.plain.speech }}"
action: notify.mobile_app_andre_s_14t_pro
enabled: true
I would like to store the Notification Part
title: Tagesplanung für den {{ now().strftime('%d.%m.%Y') }}
message: "{{ agent.response.speech.plain.speech }}"
Somehow, maybe inside an “input_text” helper so i would be able to show this also on an Lovelace Card on my Dashboard only visible for an selected user.
But how can i store this?