How to use tags in a flow

How to use tags in a flow on 2.0.x

There are a lot of questions about using the tags in the 2.0.x firmware of Homey. So here i give you a simple explanation of using tags in 2.0.x.

We start with the WHEN part

When making a flow you select a device in the WHEN part of the flow. In this example i used a Fibaro plug.
When selecting the device you get the option to choose “The power changed” f.e.
When clicked you will see the tag(s) coming with this card. We gonna use that tag later, no need in clicking it at this point!
Hit the check mark at the top right!
Your WHEN part should now look like this:

1

Now we make the AND part

Here is where we actually start using/clicking the tags.
For some occassions we can use the tags in the AND part for like checking if power goes up.
We get the logic card in here and we check “is greater than”. Then we click the tag and a page will open with all your tags. We choose the tag at the top where it states “Local tags”. We choose, in my case, the “power” tag. In the next screen we click the middle, empty line, and we fill in the value we need. In my case i used 100. Hit the check mark!
Your AND part should now look like this:

2

And the THEN part

We can do whatever we like with this. Just send a push notification to your phone.
But we can also use the tags here. For example to send the actual power in a message to your phone:

After adding a card in the THEN part we choose “Mobile” and after that we choose “Send a push notification”.
Then we have to pick a user ofcourse. And then, in the “Your message” line you can type something like: The power of your device changed and is (Now click the tag on the right side of the very same line you are typing in, select the “Power” tag on the top under Local Tags). Don’t forget to hit the save icon on the top ofcourse.
Your THEN part should look like this:

3

15 Likes
Cannot edit tags for device in flow editor
Zonnepanelen app.Flow maken
Adding tag in smart presence
Flow werkt niet, wat doe ik fout?
Use state of Fibaro Roller Shutter
Waarden van Philips Hue Motion Sensors, zijn die te verwerken in flows of hoe op te vragen?
Wenn Plug nicht erreichbar, dann Nachricht an
Verschillende scenes onder 1 modelijst
Help With a Humidity Flow
Any UK Homey Jedi’s willing to initial help a Newbie?:)... please
Probleem met aqara temperatuursensor in flow
Nest - Camera App
Aqara temperature
How to set value? Flow card
Gestion de variables (logiques)
Variabele vullen met een waarde van een sensor
Aqara & Xiaomi Smart Home - Zigbee App (v1.4.1)
Xiaomi Temperature senaor
Anyone uses aqura pressure sensor?
Netatmo CO2 niveau in flow
Heimdall - Let Homey watch over your home
Tags invullen
[Archived][APP][Pro] OpenWeatherMap
Verlichting aan op een donkere dag
Notify when sensors are offline/missing?
Beter beheersbare flows / omgekeerde flows voorkomen
MQTT Client, flow config
Echt van meerwaarde, het geld waard? One day fly?
Flow to use brightness sensor in Aqara Motion Sensor?
Can I Wear Shorts today - app not installing
Fibaro Flood Sensor - temperature
Infrarood paneel verwarming sturen op temperatuur en beweging
Licht aan op een bepaalde dag
Eurotronic Spirit thermostat - How to use actual temperature in a flow?
Tags invullen voor LUX
Fibaro motion sensor, flows en lux
Wecker nach Ereignissen im Kalender stellen
Xiami Aqara vochtsensor,
Xiaomi licht sensor
Is Fibaro Universal Sensor, FIBEFGBS-222, compatible with Homey
Schakelen als het om 7:15 onder 0 graden is
Woonkamer verlichting schakelen bij TV aan/uit
How to send a notification for a no more électricaly supplied device
Info for card flow
Aqara temperatuur/vocht sensor in een flow voor ventilatie
Flow "Apparaten heeft niet gerapporteerd voor "
Aeotec multisensor only returns 1 parameter - why?
Location and Presence (Owntracks) - HowTo
Zonwering aansturen met eigen weerstation en Open Weather
How to use temperature form netatmo weatherstation in a flow
Explanations on Flow logic
Tags für Devices erstellen
Motion detection with light sensor
Homey demo
Qubino Flush Shutter DC
Als zon een half uur schijnt, screens bedienen
Ikea Symfonisk remote
Lichtsensor stuurt niet aan als waarde bereikt wordt
Ikea Symfonisk remote
Trapverlichting en 2 sensoren
Virtual button and ifttt appley
Verständnisfrage WENN / UND
Bosch / Siemens App for Home Appliances
Can't change any value of tags in flows anymore
Help representing outside temperature in colours
Multisensor 6 gebruiken in Flows
Notification when a device is OFFLINE?
Klikken op : Pick a value
Choosing devices in Flows
Ayct 202

A long overdue explanation for newcomers. Thanks!

3 Likes

now try to add multiple tags and remove one already in the flow… does not work

Hi Guys, as a noob this is still a very bad explanation of the usage of tags.

can somebody give an example of a presence flow with actual screenshots with people tages and how to use those?

I am sorry to hear that. I did my best to explain how to use the tags in a flow.
I did not however tried to explain how to use tags in a presense flow, ur right about that. I ur interested in how to use tags in a flow then this post should suffice. If ur interested in a presense flow which works then ur in the wrong topic. I could do my best to show some tags in a presense flow if u like. If ur after a working presense flow then this topic will end in “this presense flow is not working for me” and stuff like that. So, if u don’t know how to use tags in a flow plz let me know and we will do some further explaining.

1 Like

Thank you for your answer, I guess the issue is more that as a non programmer (=True) I am looking for a simple and relatable example of a flow that uses tags. Your example above is the best I found (google skill level is ok) and still it is over my head since it seems to skip a few prerequisites that you need to know beforehand (I think).

A power example does not relate to me as something I am likely to use in the near future, presence is another matter since Homeys doesn’t work.

But al in all I am just trying to understand the logic and need to start at level 0 and no levels being skipped in the explanation :slight_smile:

Fair enough. I’ll make u a explanation how to use tags in a presence flow later today, starting from scratch. Am not gonna show u a fully working presence flow tho, just the tags part.

1 Like

How to use a tag in a presence flow.

For this there is no other apps needed.

First we start with the trigger in the WHEN part.
For this case i used the build-in presence and the first card will be “Someone came home”.

1

The AND part

For the and part we pick a build-in logic card and choose “Is exactly”.

When clicking that card a sub menu opens to the right.

There we hit the question mark on the top right.

2a

Then it opens the tags menu.Here we choose the “Name” tag on the top, Just under the 'In this flow" part.

3a

In the txt box we type the name of the user that is coming home, in this case that will be Bas.

This was a nice and simple explanation of using tags so far in a presence flow. If it’s still hard to follow, i also made a little video of it.

The WHEN part

Here u can do whatever u like and in this case i send a push notification to a mobile.
So add a card, choose “Mobile” and then “Send a push notification” .

5

In the box “Pick a user” u click and choose the name of the user u want to send the push message to.
In the below field u type ur message and here we can use the tags again by clicking the little grey tag.

So we choose the “Name” tag again from the top. After that we type “is home”.
The card should look like this now:

The total flow should now look like this:

Hope i did a better explanation this time. If u have any more questions plz feel free to ask them. Any off-topic remarks like “build-in presence is not working for me” will be deleted without further notice.

13 Likes

Wow, thank you very much. I think you made a lot of starters happy (me included) with the Tag / Flow instruction.

Thanks!

1 Like

Do you think it is also possible to make the User Name dynamic? So, where the Search field is set to a specific user, I want to use the tag ‘NAME’’ in that field. This reduces the number of flows to 1 regardless who many users you have.

Thank you!!

What I would like to have is a “where-used” function. So an overview of the tags (which exists already), but then also with a column in which flows they are used. Perhaps this is too much for a smartphone, but in the online flow-editor or as a CSV export, this would give a great overview.

Any ideas of existing solutions? Better logic offers something in this direction for their variables.

Thanks! Good explanation!

Is there a reason why it is not possible for me in most flows (eg Heimdall) to choose a tag?!?
I mean - click on it when it’s in the AND or THEN area works nice, but I have to select the appropriate devices for the IF area first but: No way. :man_shrugging::thinking:

Need to correct myself:
The way you described it here works. Thx for that Tutorial. It’s not the tutorial thats Bad but the technique behind is not mature.
However, the way thats required to make a simple „IF A then B flow“ it’s definitely not user-friendly cause when a user wants to say
„if sensor A does X then do Z“
then he wants to say that…
But here it’s required to say
„if a sensor does something, and that sensor is A and that sensor does X, then do Z“.

Not your programming, not your fault, but its a nerdy-workaround. :face_with_raised_eyebrow: Potential remains…

1 Like

Thank you for the explanation. It’s OK. But now let add in this example the possibility to count the number of times the power is below 100 (kind of the utility shortage) and of course you want to count one time only when power drop below 100 until it’s raise gain over 100. I took 100 as your example. I did it but I struggle to increment a variable define in Logic as “Niumber of Electicity Shortage”. what’s the exact syntax to increment multiple times the same variable - something like : variable1=variable+1. Could you help?

This may be the wrong thread. The linked thread describes how to perform calculations with variables. Maybe that helps?

Btw, I guess this is what you want:

1 Like

Thank you very much… I did not realize that I had to follow exactly the syntax in the example, I was using a simple parenthesis not the double parenthesis. I tested again my flow and it’s work well. I am going to record the number of electricity shortage but also the number of time the voltage is below 210V. Thank for your help.

1 Like