Hello, im a new user to Automagic with zero programming skills, so bare with me.
My goal is when a specific app sends a notification to my phone (text = "x") that it then triggers actions.
So far I think I have the actions down, but im getting lost on how to create this specific condition.
Starting flow when app has a specific message?
Moderator: Martin
Re: Starting flow when app has a specific message?
Hi,
The trigger Notification on Statusbar Displayed supplies the following variables to a flow: title, notification_text, notification_text_big. The variables are listed in the help page of the trigger ([?]-icon on the right side of the trigger type when editing a trigger).
The title-variable should be available on all devices (content depends on the app posting the notification), the other two notification-variables are not available on all devices/notifications (also depends on app).
An expression to check whether variable title contains the text x could look like this:
-trigger Notification on Statusbar Displayed: <desired app>
-condition Expression: contains(title, "x")
-->true: -action Vibrate
I recommend to use a condition Debug Dialog first instead of the condition Expression to show a popup dialog with all variables and values when the flow is executed (check Ignore ongoing events in the trigger to ignore some notifications like file downloads and 'keyboard opened'-notifications). You could also add an action Notification on Screen: {title} or Notification on Screen: {notification_text} to show the content of the variables when the flow is executed.
Regards,
Martin
The trigger Notification on Statusbar Displayed supplies the following variables to a flow: title, notification_text, notification_text_big. The variables are listed in the help page of the trigger ([?]-icon on the right side of the trigger type when editing a trigger).
The title-variable should be available on all devices (content depends on the app posting the notification), the other two notification-variables are not available on all devices/notifications (also depends on app).
An expression to check whether variable title contains the text x could look like this:
-trigger Notification on Statusbar Displayed: <desired app>
-condition Expression: contains(title, "x")
-->true: -action Vibrate
I recommend to use a condition Debug Dialog first instead of the condition Expression to show a popup dialog with all variables and values when the flow is executed (check Ignore ongoing events in the trigger to ignore some notifications like file downloads and 'keyboard opened'-notifications). You could also add an action Notification on Screen: {title} or Notification on Screen: {notification_text} to show the content of the variables when the flow is executed.
Regards,
Martin
Re: Starting flow when app has a specific message?
Is it possible to change the color of the icon after the notification containing the Expression: contains (title, 'A')?
Example: whatsapp mesage from "A", the icon turns red.
Thx.
Example: whatsapp mesage from "A", the icon turns red.
Thx.
Re: Starting flow when app has a specific message?
The notification icons color can not be changed unfortunately (not even the built-in icons of Automagic).