mirror of
https://github.com/matrix-org/matrix-spec
synced 2026-04-18 17:14:10 +02:00
Added capability
This commit is contained in:
parent
3311b084bf
commit
f3c269d951
|
|
@ -1 +1 @@
|
||||||
Feature: Update profile endpoints to become generic to support [MSC4133](https://github.com/matrix-org/matrix-spec-proposals/pull/4133) extended fields. Stabilised keys are explicitly enumerated, and custom keys must conform to the Common Namespaced Identifier Grammar.
|
Feature: Update profile endpoints to become generic to support [MSC4133](https://github.com/matrix-org/matrix-spec-proposals/pull/4133) extended fields. Extended profile fields are now supported via the new `m.profile_fields` capability. Stabilised keys are explicitly enumerated, and custom keys must conform to the Common Namespaced Identifier Grammar.
|
||||||
|
|
|
||||||
|
|
@ -86,6 +86,10 @@ paths:
|
||||||
$ref: '#/components/schemas/booleanCapability'
|
$ref: '#/components/schemas/booleanCapability'
|
||||||
description: Capability to indicate if the user can generate tokens to log further
|
description: Capability to indicate if the user can generate tokens to log further
|
||||||
clients into their account.
|
clients into their account.
|
||||||
|
m.profile_fields:
|
||||||
|
$ref: "#/components/schemas/profileFieldsCapability"
|
||||||
|
description: Capability to indicate if the user can set or modify extended profile fields.
|
||||||
|
If absent, clients SHOULD assume extended profiles are supported in the correct spec version.
|
||||||
examples:
|
examples:
|
||||||
response:
|
response:
|
||||||
value: {
|
value: {
|
||||||
|
|
@ -144,3 +148,28 @@ components:
|
||||||
example: false
|
example: false
|
||||||
required:
|
required:
|
||||||
- enabled
|
- enabled
|
||||||
|
profileFieldsCapability:
|
||||||
|
type: object
|
||||||
|
title: ProfileFieldsCapability
|
||||||
|
properties:
|
||||||
|
enabled:
|
||||||
|
type: boolean
|
||||||
|
description: True if the user can set or modify any extended profile fields, false otherwise.
|
||||||
|
example: true
|
||||||
|
allowed:
|
||||||
|
type: array
|
||||||
|
description: List of allowed custom profile field keys. This takes precedence over disallowed if both are provided.
|
||||||
|
items:
|
||||||
|
type: string
|
||||||
|
example:
|
||||||
|
- "m.example_field"
|
||||||
|
- "org.example.job_title"
|
||||||
|
disallowed:
|
||||||
|
type: array
|
||||||
|
description: List of disallowed custom profile field keys. Ignored if allowed is provided.
|
||||||
|
items:
|
||||||
|
type: string
|
||||||
|
example:
|
||||||
|
- "org.example.secret_field"
|
||||||
|
required:
|
||||||
|
- enabled
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue