So, for those coming from Google and are scratching their head how to achieve this (like I was).
The flow wanted by the original poster is possible, but you need to use Collaborative Tags (it’s a built-in app)
This is actually described in NC official docs:
https://docs.nextcloud.com/server/stable/admin_manual/file_workflows/automated_tagging.html
According to Flow, the tag(s) of a folder is somehow inheritable to its content, so basically:
- Tag the upload folder or any target folder with tag “A” (or whatever name).
- Create tag “B” (or whatever name).
- Create Flow rule, that if file system tag is “A” AND mime type is not folder, then tag the file as “B”.
- Create whatever Flow you need with files tagged as “B”.
No. 3 is important but unfortunately is not mentioned anywhere in the docs. This prevents tagging the top folder with both “A” and “B”. Depending on your use-case, you might not want the top folder to be processed at all (e.g. for time-based deletion).