diff --git a/api/client-server/create_room.yaml b/api/client-server/create_room.yaml index be99c4ab..ef207f07 100644 --- a/api/client-server/create_room.yaml +++ b/api/client-server/create_room.yaml @@ -208,10 +208,9 @@ paths: title: Power Level Event Content description: |- The power level content to override in the default power level - event. This object is applied on top of the generated power - level event prior to it being sent to the room. Defaults - to overriding nothing. - $ref: "definitions/event-schemas/power_level_content_schema.yaml" + event. This object is applied on top of the generated `m.room.power_levels`_ + event content prior to it being sent to the room. Defaults to + overriding nothing. responses: 200: description: Information about the newly created room. diff --git a/event-schemas/power_level_content_schema.yaml b/event-schemas/power_level_content_schema.yaml deleted file mode 100644 index 5859d56e..00000000 --- a/event-schemas/power_level_content_schema.yaml +++ /dev/null @@ -1,56 +0,0 @@ -# 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 \ No newline at end of file diff --git a/event-schemas/schema/m.room.power_levels b/event-schemas/schema/m.room.power_levels index 174ada82..13a44c70 100644 --- a/event-schemas/schema/m.room.power_levels +++ b/event-schemas/schema/m.room.power_levels @@ -43,7 +43,49 @@ description: |- properties: content: - $ref: "../power_level_content_schema.yaml" + 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 state_key: description: A zero-length string. pattern: '^$'