Add 404 responses to the OpenAPI of login endpoints (#2316)

Signed-off-by: Olivier 'reivilibre <oliverw@matrix.org>
This commit is contained in:
Olivier 'reivilibre 2026-02-24 14:41:27 +00:00 committed by GitHub
parent 57a1d5ad0e
commit 580298895b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 31 additions and 0 deletions

View file

@ -0,0 +1 @@
Add 404 responses to the OpenAPI of `GET /login` and `GET /auth_metadata` endpoints. The responses were already defined in text but not written in OpenAPI.

View file

@ -70,6 +70,21 @@ paths:
}
]
}
"404":
description: |-
With `M_UNRECOGNIZED`: the homeserver does not support the legacy authentication API.
(See [Authentication API discovery](/client-server-api/#authentication-api-discovery).)
content:
application/json:
schema:
$ref: definitions/errors/error.yaml
examples:
response:
value:
{
"errcode": "M_UNRECOGNIZED",
"error": "OAuth 2.0 authentication is in use on this homeserver.",
}
"429":
description: This request was rate-limited.
content:

View file

@ -195,6 +195,21 @@ paths:
"org.matrix.cross_signing_reset",
],
}
"404":
description: |-
With `M_UNRECOGNIZED`: the homeserver does not support the OAuth 2.0 API.
(See [Authentication API discovery](/client-server-api/#authentication-api-discovery).)
content:
application/json:
schema:
$ref: definitions/errors/error.yaml
examples:
response:
value:
{
"errcode": "M_UNRECOGNIZED",
"error": "Legacy authentication is in use on this homeserver.",
}
tags:
- Session management
servers: