Read-Only / Write Permissions for specific Fields in Documents #2408
Replies: 1 comment 2 replies
|
Right now the best way to handle attribute level permissions is to split your data to multiple collections. For example if you had a collection that contains user informations like: {
"name": "myname",
"theme": "blue",
"age": 25,
"vip": true,
}If you want to allow the user to update If you want all the data to still be available for read under one collection, you can create a cloud function to aggregate both collections under a 3rd unified collection that give away only read permissions. That said, with the new DB updates that are coming in Appwrite 0.12, attribute level permissions seems more feasible. That said, we have to carefully test both complexity levels that this will add, and carefully test the performance implications. |
Uh oh!
There was an error while loading. Please reload this page.
As briefly mentioned on Discord, it would be great to have a read-only / write permission for specific fields in documents.
Right now - to restrict clients from changing the entire document - we have the following inconvenient options:
Possible use cases are timestamps (like
Document createdorDocument updated) or fields, that should only be updated by a specific user (e.g. team admin).Happy to hear your thoughts on this.
All reactions