Line 2: |
Line 2: |
| | | |
| == About == | | == About == |
− | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;">
| + | |
| In many triggers, actions and constraints you will have the option to configure some textual fields. Often you will find a button next to the text entry field that contains the "..." label. This button will display a complete list of "magic text" fields that are available in the context that is being used. | | In many triggers, actions and constraints you will have the option to configure some textual fields. Often you will find a button next to the text entry field that contains the "..." label. This button will display a complete list of "magic text" fields that are available in the context that is being used. |
| | | |
Line 12: |
Line 12: |
| with ease. | | with ease. |
| | | |
− | The magic text allows some other value to be substituted at the point of invocation, rather than standard static text that will never changed. For example it's possible to add and action that reference a variable via magic text and that variable's value will be substituted at the point that action is run. | + | The magic text allows some other value to be substituted at the point of invocation, rather than standard static text that will never changed. For example it's possible to add an action that references a variable via magic text and that variable's value will be substituted at the point that action is run. |
| | | |
| Magic text can be written in 2 ways : Curly brackets {value} and square brackets [value]. Curly brackets aren't supported on very old versions like v5.20 and below but it's recommended to use it when interacting with dictionaries/arrays as with square brackets it can get confusing where you are very quickly. | | Magic text can be written in 2 ways : Curly brackets {value} and square brackets [value]. Curly brackets aren't supported on very old versions like v5.20 and below but it's recommended to use it when interacting with dictionaries/arrays as with square brackets it can get confusing where you are very quickly. |
− | </pre>
| |
| | | |
| ==<p><b>Requires a condition (loop)</b></p>== | | ==<p><b>Requires a condition (loop)</b></p>== |
Line 49: |
Line 48: |
| Returns the package name of the application that was launched, for example, if it were MacroDroid the response would be "com.arlosoft.macrodroid". | | Returns the package name of the application that was launched, for example, if it were MacroDroid the response would be "com.arlosoft.macrodroid". |
| </pre> | | </pre> |
| + | |
| === Application Launched/Closed === | | === Application Launched/Closed === |
| * '''''Application name''''' | | * '''''Application name''''' |
Line 60: |
Line 60: |
| Returns the package name of the application that was launched, for example, if it were MacroDroid the response would be "com.arlosoft.macrodroid". | | Returns the package name of the application that was launched, for example, if it were MacroDroid the response would be "com.arlosoft.macrodroid". |
| </pre> | | </pre> |
− | === Bluethooth (Device connected or device disconnected) === | + | |
| + | === Bluetooth (Device connected or device disconnected) === |
| * '''''Bluetooth device name''''' | | * '''''Bluetooth device name''''' |
| <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> | | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |
Line 69: |
Line 70: |
| {bluetooth_device_name} = Headphones 1 Pro | | {bluetooth_device_name} = Headphones 1 Pro |
| </pre> | | </pre> |
| + | |
| === Call (Active, Ended, Incoming, Missed, Outgoing) === | | === Call (Active, Ended, Incoming, Missed, Outgoing) === |
| * '''''Call group(s)''''' | | * '''''Call group(s)''''' |
Line 124: |
Line 126: |
| {sms_sim_name} = Vodafone | | {sms_sim_name} = Vodafone |
| </pre> | | </pre> |
| + | |
| === Logcat === | | === Logcat === |
| * '''''Logcat entry line''''' | | * '''''Logcat entry line''''' |
Line 153: |
Line 156: |
| <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> | | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |
| {not_action_names} - are clickable buttons or links embedded within notifications that allow users to perform specific tasks directly without opening the associated app. | | {not_action_names} - are clickable buttons or links embedded within notifications that allow users to perform specific tasks directly without opening the associated app. |
| + | </pre> |
| + | * '''''Notification timestamp''''' |
| + | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |
| + | {not_timestamp} - an integer representing the Unix time (in milliseconds) that the notification was received. For example, 1735689600000, which means that the notification was received at exactly 00:00:00:000 GMT on January 1st, 2025. |
| </pre> | | </pre> |
| * '''''Notification app name''''' | | * '''''Notification app name''''' |
Line 162: |
Line 169: |
| {not_app_package} - is the package name of the application that created the notification. | | {not_app_package} - is the package name of the application that created the notification. |
| </pre> | | </pre> |
| + | * '''''Notification channel''''' |
| + | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |
| + | {not_channel} - the name of the notification channel that the notification was sent through. This can be useful if an application has multiple notification channels. |
| + | </pre> |
| + | |
| === Spotify === | | === Spotify === |
| + | |
| * '''''Spotify track id''''' | | * '''''Spotify track id''''' |
| <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> | | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |
Line 187: |
Line 200: |
| {spotify_is_playing}- Returns a boolean state (true or false). | | {spotify_is_playing}- Returns a boolean state (true or false). |
| </pre> | | </pre> |
| + | |
| === System settings === | | === System settings === |
| * '''''System setting category''''' | | * '''''System setting category''''' |
Line 200: |
Line 214: |
| {system_setting_value} - Returns the value of the key. | | {system_setting_value} - Returns the value of the key. |
| </pre> | | </pre> |
| + | |
| + | === Text Shared to MacroDroid === |
| + | * '''''Shared Text''''' |
| + | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |
| + | {shared_text} |
| + | |
| + | Gets the text that was sent from another application (Selected text > Share text > MacroDroid) |
| + | </pre> |
| + | |
| === UI click === | | === UI click === |
| <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> | | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |
| {ui_click_text} - Gets the text it matches, most useful when the text it needs to match is a regular expression or text that changes constantly using some variable. | | {ui_click_text} - Gets the text it matches, most useful when the text it needs to match is a regular expression or text that changes constantly using some variable. |
| </pre> | | </pre> |
| + | |
| === USB device connected === | | === USB device connected === |
| * '''''USB product name''''' | | * '''''USB product name''''' |
Line 217: |
Line 241: |
| {usb_device_hash} - It is a unique identifier that is generated for each USB device. | | {usb_device_hash} - It is a unique identifier that is generated for each USB device. |
| </pre> | | </pre> |
| + | |
| === Weather === | | === Weather === |
| * '''''Temperature (Celsius)''''' | | * '''''Temperature (Celsius)''''' |
Line 250: |
Line 275: |
| {weather_conditions} - Weather conditions. | | {weather_conditions} - Weather conditions. |
| </pre> | | </pre> |
| + | |
| === Webhook URL === | | === Webhook URL === |
| * '''''Webhook caller IP address''''' | | * '''''Webhook caller IP address''''' |
Line 259: |
Line 285: |
| {webhook_caller_ip_address} = 189.172.30.212 | | {webhook_caller_ip_address} = 189.172.30.212 |
| </pre> | | </pre> |
| + | |
| ==<p><b>Does not require a trigger to operate</b></p>== | | ==<p><b>Does not require a trigger to operate</b></p>== |
| This magic text list does not need a specific trigger to appear. | | This magic text list does not need a specific trigger to appear. |
Line 290: |
Line 317: |
| === Cell connection type === | | === Cell connection type === |
| <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> | | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |
− | {cell_connection:type} | + | {cell_connection_type} |
| cell connection type e.g. 3g, 4g, 5g. | | cell connection type e.g. 3g, 4g, 5g. |
| </pre> | | </pre> |
| + | |
| === Cell id === | | === Cell id === |
| <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> | | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |
Line 675: |
Line 703: |
| <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> | | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |
| {system_time} | | {system_time} |
− | The current time as maintained by your operating system.
| + | An integer representing the current Unix time (in seconds) according to your device's internal clock. |
| + | |
| + | Unix time is the number of non-leap seconds that have elapsed since January 1, 1970, at 00:00:00 Coordinated Universal Time (UTC), a reference point in time known as the Unix epoch. |
| + | |
| + | For example, 1735689600 represents 00:00:00 GMT on January 1st, 2025. |
| </pre> | | </pre> |
| + | |
| === System time (ms) === | | === System time (ms) === |
| <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> | | <pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |
| {system_time_ms} | | {system_time_ms} |
− | The current time according to your device's internal clock, measured in milliseconds since the Unix epoch. The Unix epoch is a reference point in time, set as January 1, 1970, at 00:00:00 Coordinated Universal Time (UTC).
| + | An integer representing the current Unix time (in milliseconds) according to your device's internal clock. |
| + | |
| + | For example, 1735689600000 represents 00:00:00:000 GMT on January 1st, 2025. |
| </pre> | | </pre> |
| + | |
| === Week of year === | | === Week of year === |
| </pre><pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> | | </pre><pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;"> |