eclipse / kapua

Eclipse Public License 2.0
222 stars 160 forks source link

Admit list of tags on getDevices filter #4024

Open pintify opened 4 months ago

pintify commented 4 months ago

Is your feature request related to a problem? Please describe. In the REST API, the tagId filter in the getDevices is really powerful but I'm currently stacking multiple requests with different tagId and it seems like there should be the possibility to request them on an OR relationship that allows me to request all devices that fits with multiple tagIds at the same time, which is not very complicated to reproduce on the database request internally. Repeating the requests and removing duplicates is a bit overheaded.

Describe the solution you'd like I'd suggest modifying the tagId filter on getDevices to become an array of tags (.../devices?tagId=car&tagId=house).

Additional context It would make it more similar to the matchTerm filter which is also very powerful