api flow looks like 1) get all documents based on...
# spicedb
a
api flow looks like 1) get all documents based on the organization (skipping this part, just raw SQL here since the data is taken from usual database) 2) based on the relationship document<>user(SpiceDB) we can get user_ids 3) I need not only user_id, but role that this user has(SpiceDB) so basically we have object_type - document object_id - {ID_OF_EACH_DOC} role - {need this} subject_type - user subject_id - {need this}