Merge pull request #1879 from matrix-org/travis/fix-capabilities

Correctly nest the capabilities response object
pull/977/head
Travis Ralston 6 years ago committed by GitHub
commit 72242e4ebb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -62,44 +62,48 @@ paths:
schema: schema:
type: object type: object
required: ["capabilities"] required: ["capabilities"]
additionalProperties:
type: object
description: |-
The custom capabilities the server supports, using the
Java package naming convention.
properties: properties:
"m.change_password": capabilities:
type: object type: object
title: Capabilities
description: |- description: |-
Capability to indicate if the user can change their password. The custom capabilities the server supports, using the
title: ChangePasswordCapability Java package naming convention.
additionalProperties:
type: object
properties: properties:
enabled: "m.change_password":
type: boolean
description: |-
True if the user can change their password, false otherwise.
example: false
required: ['enabled']
"m.room_versions":
type: object
description: The room versions the server supports.
title: RoomVersionsCapability
properties:
default:
type: string
description: |-
The default room version the server is using for new rooms.
example: "1"
available:
type: object type: object
description: |- description: |-
A detailed description of the room versions the server supports. Capability to indicate if the user can change their password.
additionalProperties: title: ChangePasswordCapability
type: string properties:
title: RoomVersionStability enabled:
enum: [stable, unstable] type: boolean
description: The stability of the room version. description: |-
required: ['default', 'available'] True if the user can change their password, false otherwise.
example: false
required: ['enabled']
"m.room_versions":
type: object
description: The room versions the server supports.
title: RoomVersionsCapability
properties:
default:
type: string
description: |-
The default room version the server is using for new rooms.
example: "1"
available:
type: object
description: |-
A detailed description of the room versions the server supports.
additionalProperties:
type: string
title: RoomVersionStability
enum: [stable, unstable]
description: The stability of the room version.
required: ['default', 'available']
429: 429:
description: This request was rate-limited. description: This request was rate-limited.
schema: schema:

@ -0,0 +1 @@
Support optional features by having clients query for capabilities.
Loading…
Cancel
Save