-
Notifications
You must be signed in to change notification settings - Fork 16
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
feat: add new API definitions for relation metadata & assignable types #27
Conversation
The idea here would be use to If the @rhamzeh I recognize the impact of this on SDKs and tooling, but I think it's warranted to make the model of a TypeDefinition more clear and it also supports our use case for ListObjects more accurately. Code in the server becomes: typedef := datastore.ReadTypeDefinition("document")
relations := typedef.GetRelations()
relation, ok := relations["viewer"]
if !ok { // relation doesn't exist }
typeinfo := relation.GetTypeInfo() What do you think? Can we proceed with this approach? |
By the way, should we bring all the proto files to |
Not all of them. If we evolve our grpc service API definitions then we can start a new |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…elRequest` - BREAKING: exported type `TypeDefinitions` is now `WriteAuthorizationModelRequest` This is only a breaking change on the SDK, not the API. It was changed to conform to the proto changes in [openfga/api](openfga/api#27). It makes the type name more consistent and less confusing (normally people would incorrectly assume TypeDefinitions = TypeDefinition[]). - chore(deps): upgrade dependencies
Description
This starts the beginning of a new OpenFGA model package
v2beta1
which contains the preliminary definitions for the type info in TypeDefinitions.References
Review Checklist
main