Open aaguiarz opened 1 year ago
"The Read API will only return all the stored relationships that match the query specification. It does not expand or traverse the graph by taking the authorization model into account." docs Would it be possible (considered in the design) later taking the authorization model into account?
The goal of the Read API is to read the tuples you've written.
ListObjects / ListRelations (available in the SDKs for now) / ListUsers (in the roadmap) are the endpoints you'd use if you want to query the FGA store taking into account the relations defined in the authorization model.
Hi Team, Can we have the feature to fetch data with multiple relationships? Below is the request payload.
{
"object": "team:x",
"relation": ["admin", "member"],
}
Here fetch all members and admin of a team x. And the response is like.
{
"tuples": [
{
"key": {
"user": "user:3",
"relation": "member",
"object": "doc:2",
"condition": null
},
"timestamp": "2023-12-11T06:26:04.136575Z"
},
{
"key": {
"user": "user:38",
"relation": "admin",
"object": "doc:2",
"condition": null
},
"timestamp": "2023-12-11T06:36:50.617780Z"
},
{
"key": {
"user": "user:34",
"relation": "admin",
"object": "doc:2",
"condition": null
},
"timestamp": "2023-12-11T06:36:50.630055Z"
}
}
The current implementation of the Read API lets you filter read tuples in a few ways:
user-1
)user-1
anddocument-1
user-1
document-1
withread
relationship)However, there are several scenarios where you need more flexibility:
permission:{org}/read
, I want to filter byorg
.