Skip to content
Back

permission to read Users

  • 0
  • Databases
  • Auth
  • Web
  • Cloud
Roncho
18 Dec, 2024, 20:31

in my app (next.js, hono) I work with all the collections, can read and write because i gave the registered users permission to do so. But since the users is a different kind of collection, I don't see where I can set the permissions to it. I want to give registered users the ability to read the whole users list. How?

TL;DR
Developers want to grant registered users permission to read the entire users list in their app, but web sdk limitations make it challenging. Instead of granting access to sensitive user objects, the recommendation is to maintain a separate users collection with limited user profile information for reading. This way, developers can control what data users have access to. In Next.js with Honoo, permissions can be set for collections, but for the users collection, developers should create a separate users collection with necessary permissions for reading.
Kenny
18 Dec, 2024, 20:48

Using the web sdk you really can't do that, but ultimately you really shouldn't allow users to read other user objects as they contain sensitive information. What I would recommend doing instead in maintain a users collection that stores stuff like user name, profile picture, ect. And giving them the ability to read from that.

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