Compare commits

...

5 commits

Author SHA1 Message Date
Logan Devine f802f81de6
Merge b41698af55 into 4c2bb5aae1 2026-07-17 19:04:13 -07:00
networkException 4c2bb5aae1
Clarify user avatar_urls to always use MXC URIs (#2422)
Some checks failed
Spec / 🔎 Validate OpenAPI specifications (push) Has been cancelled
Spec / 🔎 Check Event schema examples (push) Has been cancelled
Spec / 🔎 Check OpenAPI definitions examples (push) Has been cancelled
Spec / 🔎 Check JSON Schemas inline examples (push) Has been cancelled
Spec / ⚙️ Calculate baseURL for later jobs (push) Has been cancelled
Spec / 📢 Run towncrier for changelog (push) Has been cancelled
Spell Check / Spell Check with Typos (push) Has been cancelled
Spec / 🐍 Build OpenAPI definitions (push) Has been cancelled
Spec / 📖 Build the spec (push) Has been cancelled
Spec / 🔎 Validate generated HTML (push) Has been cancelled
Spec / 📖 Build the historical backup spec (push) Has been cancelled
Spec / Create release (push) Has been cancelled
Previously the spec would use a mix of `string`, `URI`
and `MXC URI` for values of a user's `avatar_url` in
different apis (like `m.room.member`, `m.presence`,
CS profile endpoints).

This clarification updates all occurances to be MXC URIs,
prompted by https URIs `m.room.member#avatar_url` events
in the wild.

Signed-off-by: networkException <git@nwex.de>
2026-07-17 13:27:19 +02:00
Logan Devine b41698af55
Remove line wrapping from changelog
Co-authored-by: Travis Ralston <travpc@gmail.com>
2026-07-13 17:56:24 -07:00
Logan Devine 89cc8a71a7
Specify behavior of the m.policy room type, fix changelog
Signed-off-by: Logan Devine <logan@zirco.dev>
2026-07-13 17:45:29 -07:00
Logan Devine 94dd59b049
Spec for MSC3784: Using room type of m.policy for policy rooms
Signed-off-by: Logan Devine <logan@zirco.dev>
2026-07-12 11:21:25 -07:00
11 changed files with 21 additions and 5 deletions

View file

@ -0,0 +1 @@
Introduce room type `m.policy` to indicate rooms likely to contain policy lists, as per [MSC3784](https://github.com/matrix-org/matrix-spec-proposals/pull/3784).

View file

@ -0,0 +1 @@
Use MXC URI type for all user `avatar_url` fields. Contributed by @networkException.

View file

@ -3820,6 +3820,7 @@ the create room request.
In this specification the following room types are specified: In this specification the following room types are specified:
* [`m.space`](#spaces) * [`m.space`](#spaces)
* [`m.policy`](#moderation-policy-lists)
Unspecified room types are permitted through the use of Unspecified room types are permitted through the use of
[Namespaced Identifiers](/appendices/#common-namespaced-identifier-grammar). [Namespaced Identifiers](/appendices/#common-namespaced-identifier-grammar).

View file

@ -22,6 +22,10 @@ restrictions on how the rooms can be configured in terms of
[join rules](#mroomjoin_rules), [history visibility](#room-history-visibility), [join rules](#mroomjoin_rules), [history visibility](#room-history-visibility),
encryption, etc. encryption, etc.
A moderation policy list may be designated by the [`m.policy` room type](#types),
however, policy events may still be sent in rooms without this room type. Sending
messages in rooms with the `m.policy` room type is discouraged, but not forbidden.
There are currently 3 kinds of entities which can be affected by rules: There are currently 3 kinds of entities which can be affected by rules:
`user`, `server`, and `room`. All 3 are described with `user`, `server`, and `room`. All 3 are described with
`m.policy.rule.<kind>` state events. The `state_key` for a policy rule `m.policy.rule.<kind>` state events. The `state_key` for a policy rule

View file

@ -54,7 +54,8 @@ properties:
example: true example: true
avatar_url: avatar_url:
type: string type: string
format: uri format: mx-mxc-uri
pattern: "^mxc:\\/\\/"
description: The URL for the room's avatar, if one is set. description: The URL for the room's avatar, if one is set.
example: "mxc://example.org/abcdef" example: "mxc://example.org/abcdef"
join_rule: join_rule:

View file

@ -340,7 +340,8 @@ paths:
description: The display name of the user this object is representing. description: The display name of the user this object is representing.
avatar_url: avatar_url:
type: string type: string
format: uri format: mx-mxc-uri
pattern: "^mxc:\\/\\/"
description: The avatar of the user this object is representing, as an [`mxc://` description: The avatar of the user this object is representing, as an [`mxc://`
URI](/client-server-api/#matrix-content-mxc-uris). URI](/client-server-api/#matrix-content-mxc-uris).
description: A map from user ID to a RoomMember object. description: A map from user ID to a RoomMember object.

View file

@ -238,7 +238,8 @@ paths:
title: Display name title: Display name
avatar_url: avatar_url:
type: string type: string
format: uri format: mx-mxc-uri
pattern: "^mxc:\\/\\/"
title: Avatar Url title: Avatar Url
events_before: events_before:
type: array type: array

View file

@ -90,7 +90,8 @@ paths:
description: The display name of the user, if one exists. description: The display name of the user, if one exists.
avatar_url: avatar_url:
type: string type: string
format: uri format: mx-mxc-uri
pattern: "^mxc:\\/\\/"
example: mxc://bar.com/foo example: mxc://bar.com/foo
description: The avatar url, as an [`mxc://` description: The avatar url, as an [`mxc://`
URI](/client-server-api/#matrix-content-mxc-uris), URI](/client-server-api/#matrix-content-mxc-uris),

View file

@ -172,6 +172,8 @@ paths:
example: John Doe example: John Doe
avatar_url: avatar_url:
type: string type: string
format: mx-mxc-uri
pattern: "^mxc:\\/\\/"
description: |- description: |-
The avatar URL for the user's avatar. MUST either be omitted or set to The avatar URL for the user's avatar. MUST either be omitted or set to
`null` if the user does not have an avatar set. `null` if the user does not have an avatar set.

View file

@ -12,6 +12,8 @@
"properties": { "properties": {
"avatar_url": { "avatar_url": {
"type": "string", "type": "string",
"format": "mx-mxc-uri",
"pattern": "^mxc:\\/\\/",
"description": "The current avatar URL for this user, if any." "description": "The current avatar URL for this user, if any."
}, },
"displayname": { "displayname": {

View file

@ -53,7 +53,8 @@ properties:
avatar_url: avatar_url:
description: 'The avatar URL for this user, if any.' description: 'The avatar URL for this user, if any.'
type: string type: string
format: uri format: mx-mxc-uri
pattern: "^mxc:\\/\\/"
displayname: displayname:
description: 'The display name for this user, if any.' description: 'The display name for this user, if any.'
type: type: