I cannot use a newly added file with filenotify

I have just added a file to which I want to write some data periodically called “PDC.csv”


notify:
  - platform: file
    name: filenotify
    filename: /config/data/file.csv
    timestamp: true
  - platform: file
    name: filenotify2
    filename: /config/data/file2.csv
    timestamp: true
  - platform: file
    name: filenotify3
    filename: /config/data/F1F2F3.csv
    timestamp: true
  - platform: file
    name: filenotify_Leam
    filename: /config/data/Leam.csv
    timestamp: true
  - platform: file
    name: filenotify_Leam_daily
    filename: /config/data/Leam_daily.csv
    timestamp: true
  - platform: file
    name: filenotify_Leam_daily_inverter
    filename: /config/data/Leam_daily_inverter.csv
    timestamp: true
  - platform: file
    name: filenotify_BMS
    filename: /config/data/BMS.csv
    timestamp: true
  - platform: file
    name: filenotify_Leam_daily_solar
    filename: /config/data/Solar.csv
    timestamp: true
  - platform: file
    name: filenotify_CPDC
    filename: /config/data/PDC.csv
    timestamp: true
    

I’ve restarted Home Assistant, however, while I can see the previously created notifyfile services, I cannot see the new one under “developer tools”/“actions” when I start typing notify…

It’s also not visible here

If I try and add it through the UI…
image

it appears as “file” and not “filenotify”

Probably a browser cache issue.
Clear your browser cache.

I just checked on my iPhone and it doesn’t show up

Try reading this thread then.

That thread is from 2018; I set up my working file notifications no more than 2 years ago; now something has changed again. I really need something more recent

you didnt read the last posts there obviously?

its all there

Is it a long time since the last HA core update?
There were a breaking change a few months back.

I have now; but that’s not the problem I have. Even if I use “notify.send_message”, the entity that I defined in the yaml or through the UI (which shows as “file” rather than “filenotify”, see picture above) does not show up

I have these

sensor:

  - platform: file
    file_path: /config/logging/filed/filed_notifications.txt
    name: Filed notifications
    <<: &truncate_value
      value_template: >
        {% if value is not none %}
          {% if value|length < 255 %} {{value}}
          {% else %} Truncated: {{value|truncate(240,True, '')}}
          {% endif %}
        {% endif %}

for the sensor and

notify:
# https://www.home-assistant.io/integrations/file/#notifications
  - name: filed_notifications
    platform: file
    filename: /config/logging/filed/filed_notifications.txt
  #  timestamp: False

for the notifications from before

resulting in the File integration overview

but, now I reread your OP: are you only having an issue with the PDC.csv? and all others work correctly?

Yes, all the others work correctly.

I finally figured it out
I needed to get the entity ID of the file service I created


This cannot be changed and it confusingly looks like an action name

However, the service I need to call is “Notifications: send a notification message” and then select the entity from above

So while, previously set up notifications included the target file in the action, now you have to specify the generic action and then specify the “target file”