-
Notifications
You must be signed in to change notification settings - Fork 499
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
Use the stable hierarcy endpoint from MSC2946 #5144
Comments
The other thing to check is if the |
@clokep I can do it I'm just wondering what you mean about:
Here is my use case: To get the list of children for |
Yes, it should work, it might be inefficient, however. Are you calling the API with a max-depth? By default the API will paginate through the entire tree of spaces.
This is referencing a minor change to the API shape that gets returned. If we use the example from the spec, I've highlighted the field that was removed: {
"next_batch": "next_batch_token",
"rooms": [
{
"avatar_url": "mxc://example.org/abcdef",
"canonical_alias": "#general:example.org",
"children_state": [
{
"content": {
"via": [
"example.org"
]
},
- "room_id": "!space:example.org",
"origin_server_ts": 1629413349153,
"sender": "@alice:example.org",
"state_key": "!a:example.org",
"type": "m.space.child"
}
],
"guest_can_join": false,
"join_rule": "public",
"name": "The First Space",
"num_joined_members": 42,
"room_id": "!space:example.org",
"room_type": "m.space",
"topic": "No other spaces were created first, ever",
"world_readable": true
}
]
}
|
Thanks for your answer. We actually call the API with a |
Then yes, that should work fine! |
It seems the |
MSC2946 has completed FCP and Synapse is implementing the stable endpoint (see matrix-org/synapse#11329). It would be nice for Element iOS to implement the following so that the unstable endpoints can be deprecated:
/_matrix/client/v1/rooms/{roomID}/hierarchy
endpoint.room_id
is not accessed via the list ofchildren_state
(this is nested under the room information and should be unnecesary).This should most likely be implemented to attempt using the stable endpoint before falling back to the unstable endpoint. Please let me know if you have any questions.
The text was updated successfully, but these errors were encountered: