verdverm.com
05/29/2025, 12:05 AMgroup#owner | group#member into something like group#*? Is this catchall not recommended?
2. I'm modelling public vs private in the application logic/db, is there a pattern for this in spicedb?
3. For public groups, I'd like to allow any user to join/leave. Is this something that can be modelled in spice?
4. I'd like non-members to be able to view public groups. Should I add user to the read permission?
definition user {}
definition group {
relation owner: user
relation member: user
permission write = owner
permission read = member + write
}yetitwo
05/29/2025, 12:59 AMuser:*) are typically the way that you say something is "public"
1. sure, have a join (and/or leave) permission on the group and phrase it in terms of the aforementioned subject wildcards
for the last part:
definition user {}
definition group {
relation owner: user
relation member: user
relation public: user:*
permission write = owner
permission read = member + public
}
and then you'd write a public@user:* on the group to make it publicverdverm.com
05/29/2025, 4:24 AMdefinition superuser {} and add it to the relations on every resource?yetitwo
05/29/2025, 1:35 PMdefinition platform {} objectyetitwo
05/29/2025, 1:35 PMyetitwo
05/29/2025, 1:35 PMyetitwo
05/29/2025, 1:36 PMverdverm.com
05/29/2025, 6:46 PM