B22DCCN393 Nguyễn Việt Huy
03/05/2026, 7:57 AMA is an ancestor of another instance B through a specific relation.
For example:
• A is the manager of B
• B manages C
I would like to be able to query and get a result indicating that A is effectively an ancestor of C.
Could you please consider providing this feature or guidance on how to achieve this with the current system?Ask Inkeep
03/05/2026, 7:57 AMAsk Inkeep
03/05/2026, 7:57 AMA is an ancestor of instance B through a chain of relations. The current documented approach focuses on *deriving permissions* through relationships rather than querying the relationship graph itself.
Suggested Next Steps
For this feature request, I recommend reaching out to the Permit.io team directly:
• Reach out over Email
Check out these potentially useful sources:
• What is Relationship-Based Access Control (ReBAC) ?
• Fintech / Banking Demo Application
• Concepts / Glossary
Would you like me to provide a general answer based on my knowledge of how such ancestor queries might be approached?Ask Inkeep
03/05/2026, 7:58 AMB22DCCN393 Nguyễn Việt Huy
03/05/2026, 7:59 AMA is an ancestor of instance B.
For example:
• A is the manager of B
• B manages C
I want to query and determine that A is an ancestor of C.
So in this case, Derivation is not relevantB22DCCN393 Nguyễn Việt Huy
03/05/2026, 7:59 AMAsk Inkeep
03/05/2026, 7:59 AMAsk Inkeep
03/05/2026, 8:00 AMawait permit.api.relationshipTuples.list({
tenant: "default",
relation: "parent",
subject: "file:file-1",
subjectType: "file",
object: "folder:folder-1",
objectType: "folder",
page: 1,
perPage: 20,
include_total_count: true
}) ;
Or via REST API with filters for subject, object, relation, subject_type, object_type, and tenant.
(2)
*The Limitation*
The available sources describe how to *list direct relationship tuples* (e.g., A manages B, B manages C) , but they *do not document a built-in function to query transitive/ancestor relationships* (e.g., "is A an ancestor of C through a chain of manages relations?") .
The relationship tuple APIs return direct relationships only—you would need to traverse the graph yourself by querying each hop.
*Recommendation*
This sounds like a feature request for a transitive relationship query capability. I recommend reaching out to the Permit.io team directly:
• Reach out over Email
Check out these potentially useful sources:
• Filter Relationship Tuples
• List Relationship Tuples (Node.js SDK)
Would you like a general answer on how you might implement ancestor traversal logic using the existing tuple listing APIs?Ask Inkeep
03/05/2026, 8:00 AMAsk Inkeep
03/05/2026, 8:02 AMdavid
03/05/2026, 8:11 AMOr Weis
03/05/2026, 8:15 AM