@@ -121,6 +121,25 @@ For more customizable notifications, use the `ntfy.publish` action instead of `n
121121-
`email` :
Specify the address to forward the notification to, for example `[email protected] `. 122122- `call` : Phone number to call and read the message out loud using text-to-speech. Requires ntfy Pro and prior phone number verification.
123123- `icon` : Include an icon that will appear next to the text of the notification. Only JPEG and PNG images are supported.
124+ - `view` : Add **view** button actions that open a website or app when the action button is tapped.
125+ - `label` : Label of the view action button in the notification.
126+ - `url` : URL to open when action is tapped.
127+ - `clear` : Clear notification after action button is tapped.
128+ - `position` : The order of the buttons. Used when defining different action types.
129+ - `broadcast` : Add **broadcast** button actions that sends an Android broadcast intent when the action button is tapped.
130+ - `label` : Label of the broadcast action button in the notification.
131+ - `intent` : Android intent name, default is `io.heckel.ntfy.USER_ACTION`
132+ - `extras` : Android intent extras (key-value pairs).
133+ - `clear` : Clear notification after action button is tapped
134+ - `position` : The order of the buttons. Used when defining different action types.
135+ - `http` : Add **http** button actions that sends an Android broadcast intent when the action button is tapped.
136+ - `label` : Label of the broadcast action button in the notification.
137+ - `url` : URL to which the HTTP request will be sent.
138+ - `method` : HTTP method to use for request, default is `POST`
139+ - `headers` : HTTP headers to pass in request (key-value pairs).
140+ - `body` : Payload to send in the HTTP body.
141+ - `clear` : Clear notification after action button is tapped.
142+ - `position` : The order of the buttons. Used when defining different action types.
124143
125144{% details "Example YAML configuration" %}
126145
@@ -135,6 +154,27 @@ data:
135154 click: "https://homeassistant.local"
136155 tags:
137156 - rotating_light
157+ http:
158+ - label: Throttle server load
159+ url: https://api.example.com/
160+ method: POST
161+ headers:
162+ x-client: HomeAssistant
163+ Authorization: "Bearer zAzsx1sk.."
164+ body: "{\" action\" : \" throttle\" }"
165+ position: 1
166+ broadcast:
167+ - label: Set early alarm
168+ intent: com.urbandroid.sleep.alarmclock.ALARM_STATE_CHANGE
169+ extras:
170+ alarm_label: Work emergency
171+ alarm_enabled: true
172+ position: 2
173+ view:
174+ - label: "Open Server Dashboard"
175+ url: "https://grafana.example.com/d/server-overview"
176+ clear: true
177+ position: 3
138178target:
139179 entity_id: notify.mytopic
140180` ` `
0 commit comments