More than one SMTP "notifier"?

Hey everyone, This is my 1st post and I just started working on my HASS implementation about a week ago.

I’m using HA in an iocage “jail” on my freenas 11.2 homeserver.

So far I’ve figured out most things but ran into an issue.

In my configuration.yaml I have a working SMTP notifier like this:

  - name: notifier_sms_dad
    platform: smtp
    server: smtp.gmail.com
    port: 587
    timeout: 15
    sender: [email protected]
    encryption: starttls
    username: [email protected]
    password: secret
    recipient: 
     - [email protected]
    sender_name: My Home Assistant

Great! that works, but when I try to create another one like this:

notify:
  - name: notifier_sms_liam
    platform: smtp
    server: smtp.gmail.com
    port: 587
    timeout: 15
    sender: [email protected]
    encryption: starttls
    username: [email protected]
    password: secret
    recipient: 
     - [email protected]
    sender_name: Smusz Home Assistant

I can test the config, restart the server, and all is good.

HOWEVER …

I can only use one of the services, usually the “2nd” one in the yaml file (last one to load).

I can use the service “notify.notifier_sms_liam” but the 1st one I configured: notify.notifier_sms_dad is now gone?

On the doc page it says you can create as many of these as you might need but I’m stumped?

What is your question?

Sorr @nickrout, Had posted before finishing… was re-editing.

1 Like

are you repeating the notify: line? You shouldn’t. It should be

notify:
  - name: notifier_sms_liam
    platform: smtp 
    rest of defintion
  - name: notfifier_sms_dad
    platform: smtp
    etc...
1 Like

Ahhhh !! Makes sense!

I’ll fix and reply once fixed.

All working … Thanks!! Just needed to understand the structure better.

Appreciate the quick response!!

Pleased to help, glad you got it going.