Add general clarity to the /createRoom endpoint
This commit does a number of things:
* Minor formatting/alignment changes
* Document the room_alias response key. This could be deprecated now, or forfeited, if needed.
* Remove the guest_can_join parameter - it is not actually supported
* Document the previously undocumented power_level_content_override parameter
* Clarify that the room_id is required on the response
* More clearly spell out which events are created as part of the request
* Clarify how the room alias becomes the canonical alias
* Clarify how the `visibility` may be used to determine a default preset to apply
* Document the `m.federate` creation content parameter, adding an option for the homeserver to define a default value
References:
* Preset being inferred by the visibility: cd32c19a60/synapse/handlers/room.py (L172-L177)
* Power level content overrides:
* https://github.com/matrix-org/synapse/blob/master/synapse/handlers/room.py#L198
* https://github.com/matrix-org/synapse/blob/master/synapse/handlers/room.py#L335-L359
* Aliases becoming canonical: https://github.com/matrix-org/synapse/blob/master/synapse/handlers/room.py#L366-L370
* `m.federate` landing in the create event: https://github.com/matrix-org/synapse/blob/master/synapse/handlers/room.py#L311-L315
Fixes https://github.com/matrix-org/matrix-doc/issues/1243
Fixes https://github.com/matrix-org/matrix-doc/issues/1471
Inspired by https://github.com/matrix-org/matrix-doc/issues/1213
pull/977/head
parent
669d526ea7
commit
45c68e323a
@ -0,0 +1,56 @@
|
||||
# Copyright 2018 New Vector Ltd
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
properties:
|
||||
ban:
|
||||
description: The level required to ban a user. Defaults to 50 if unspecified.
|
||||
type: number
|
||||
events:
|
||||
additionalProperties:
|
||||
type: number
|
||||
description: The level required to send specific event types. This is a mapping from event type to power level required.
|
||||
title: Event power levels
|
||||
type: object
|
||||
events_default:
|
||||
description: |-
|
||||
The default level required to send message events. Can be
|
||||
overridden by the ``events`` key. Defaults to 0 if unspecified.
|
||||
type: number
|
||||
invite:
|
||||
description: The level required to invite a user. Defaults to 50 if unspecified.
|
||||
type: number
|
||||
kick:
|
||||
description: The level required to kick a user. Defaults to 50 if unspecified.
|
||||
type: number
|
||||
redact:
|
||||
description: The level required to redact an event. Defaults to 50 if unspecified.
|
||||
type: number
|
||||
state_default:
|
||||
description: |-
|
||||
The default level required to send state events. Can be overridden
|
||||
by the ``events`` key. Defaults to 50 if unspecified, but 0 if
|
||||
there is no ``m.room.power_levels`` event at all.
|
||||
type: number
|
||||
users:
|
||||
additionalProperties:
|
||||
type: number
|
||||
description: The power levels for specific users. This is a mapping from ``user_id`` to power level for that user.
|
||||
title: User power levels
|
||||
type: object
|
||||
users_default:
|
||||
description: |-
|
||||
The default power level for every user in the room, unless their
|
||||
``user_id`` is mentioned in the ``users`` key. Defaults to 0 if
|
||||
unspecified.
|
||||
type: number
|
||||
type: object
|
Loading…
Reference in New Issue