Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add find_objects and find_subjects to Directory client. #28

Merged
merged 1 commit into from
Apr 5, 2024
Merged

Conversation

ronenh
Copy link
Contributor

@ronenh ronenh commented Apr 4, 2024

This change exposes the gRPC GetGraph API as two methods on the Directory client.

Directory.find_objects takes a subject (type and id), and object type, and a relation or permission and returns all the objects of the specified type on which the subject has the given relation or permission.

Directory.find_subjects searches in the opposite direction and returns all the subjects of the specified type that have a given relation on permission on an object.

@ronenh ronenh merged commit e2d2ee2 into main Apr 5, 2024
3 checks passed
@ronenh ronenh deleted the get-graph branch April 5, 2024 13:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants