Skip to content

Commit 32b1f05

Browse files
authored
Clarify some string formats of room summary endpoint (#2158)
1 parent 7bcc3ec commit 32b1f05

File tree

4 files changed

+15
-1
lines changed

4 files changed

+15
-1
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Add `/_matrix/client/v1/room_summary/{roomIdOrAlias}` and extend `/_matrix/client/v1/rooms/{roomId}/hierarchy` with the new optional properties `allowed_room_ids`, `encryption` and `room_version` as per [MSC3266](https://github.com/matrix-org/matrix-spec-proposals/pull/3266).

data/api/client-server/definitions/public_rooms_chunk.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ title: "PublishedRoomsChunk"
1717
properties:
1818
canonical_alias:
1919
type: string
20+
format: mx-room-alias
21+
pattern: "^#"
2022
description: The canonical alias of the room, if any.
2123
example: "#general:example.org"
2224
name:
@@ -29,6 +31,8 @@ properties:
2931
example: 42
3032
room_id:
3133
type: string
34+
format: mx-room-id
35+
pattern: "^!"
3236
description: The ID of the room.
3337
example: "!abcdefg:example.org"
3438
topic:

data/api/client-server/definitions/room_summary.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@ allOf:
2727
type: array
2828
items:
2929
type: string
30+
format: mx-room-id
31+
pattern: "^!"
3032
description: |-
3133
If the room is a [restricted room](/server-server-api/#restricted-rooms), these are the room IDs which
3234
are specified by the join rules. Empty or omitted otherwise.

data/api/client-server/room_summary.yaml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,13 @@ paths:
4646
required: true
4747
example: "#monkeys:matrix.org"
4848
schema:
49-
type: string
49+
oneOf:
50+
- type: string
51+
format: mx-room-id
52+
pattern: "^!"
53+
- type: string
54+
format: mx-room-alias
55+
pattern: "^#"
5056
- in: query
5157
name: via
5258
description: |-
@@ -60,6 +66,7 @@ paths:
6066
type: array
6167
items:
6268
type: string
69+
format: mx-server-name
6370
responses:
6471
"200":
6572
description: A summary of the room.

0 commit comments

Comments
 (0)