Back

Appwrite labels list?

  • 0
  • Self Hosted
  • Web
ThisIsStep2
16 Apr, 2024, 11:11

i try to set permissions on my collection, i'd like to set labels, that only Admin label, can perform something but it doesn't seems to exists Is there a way like Teams, to add/list/edit labels?

TL;DR
Appwrite labels cannot be listed individually; they are just additional labels that can be added to users. You can use a specific API call to list users with a specific label. Labels cannot be created or deleted independently. The UI issue may need to be reported on GitHub for a fix. Permissions based on labels can be set with the API, but adding/listing/editing labels as separate entities is not supported.
ThisIsStep2
16 Apr, 2024, 11:13

and the ui is broken...

Guri
16 Apr, 2024, 11:48

Make a issue for this in github they will fix it

ideclon
16 Apr, 2024, 14:38

I’m not clear what you mean by “doesn’t seem to exist”?

ideclon
16 Apr, 2024, 14:40

No, you can’t list Labels - Labels aren’t an independent thing which can be created/deleted - they’re just labels you can add to a User

ThisIsStep2
16 Apr, 2024, 14:45

Thanks! So it means i cant find users that has the same label?

ThisIsStep2
16 Apr, 2024, 14:45

created !

ThisIsStep2
16 Apr, 2024, 14:46

when hovering it says "Not found". so i guess. it's doesn't exist? what else can not be found when hovering the label? i dont know

ideclon
16 Apr, 2024, 14:48

If you mean can you get a list of all users with a specific label, yes, you can call users.list([ Query.contains("labels", "labelToFind") ]) (note that this will only work from the server side API, and requires Appwrite 1.5 for the contains Query)

ideclon
16 Apr, 2024, 14:49

I’m not sure what’s going on with your UI there, but labels can’t be found or not found - they’re not a thing that exists (this isn’t great wording, but I can’t think of better rn)

ThisIsStep2
17 Apr, 2024, 07:18

Thanks for that !

Arman
17 Apr, 2024, 07:22

Thanks for sharing, I'll look into it 🙏

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more