homeassistant-ntfy.sh
homeassistant-ntfy.sh copied to clipboard
Not receiving message with data properties
Hi,
I succeed to configure the plugin and send message to my Ntfy via Home Assistant, so thank you for that ! But there is a problem, when I put data properties like "priority" or "click", I don't receive any message. Here are Home Assistant logs output:
Logger: custom_components.ntfy.notify Source: custom_components/ntfy/notify.py:89 Integration: ntfy (documentation, issues) First occurred: 10:29:29 (9 occurrences) Last logged: 11:47:53
Error while sending ntfy.sh message: 400 Client Error: Bad Request for url: https://###/
To test, I used your codes snippets (by replacing service by my ntfy service) like this one:
action:
- service: notify.my_ntfy
data:
message: "This is a test message."
title: "ntfy Test"
data:
priority: 10
How did you rename the service to your own and got it working? It's not working on my end.
How did you rename the service to your own and got it working? It's not working on my end.
In the configuration.yaml:
notify:
- name: "Ntfy Test"
platform: ntfy
...
- name: "Ntfy 3D Print"
platform: ntfy
...
You have to restart completly home assistant, after that you can use them directly. In my case:
- notify.ntfy_test
- notify.ntfy_3d_print
Here the action in one of my automation for example:
action:
- service: notify.ntfy_3d_print
Since the issue is still open... the test snippets in the repository are wrong. the priorities range had a max of 5 so a priority of 10 will result in a 400 Bad Request