diff --git a/api/client-server/registration.yaml b/api/client-server/registration.yaml index a161c79b..11587cb4 100644 --- a/api/client-server/registration.yaml +++ b/api/client-server/registration.yaml @@ -276,3 +276,47 @@ paths: responses: 200: description: An email was sent to the given address + "/account/deactivate": + post: + summary: "Deactivate a user's account." + description: |- + Deactivate the user's account, removing all ability for the user to + login again. + + This API endpoint uses the `User-Interactive Authentication API`_. + + An access token should be submitted to this endpoint if the client has + an active session. + + The homeserver may change the flows available depending on whether a + valid access token is provided. + security: + - accessToken: [] + parameters: + - in: body + name: body + schema: + type: object + properties: + auth: + description: |- + Additional authentication information for the user-interactive authentication API. + "$ref": "definitions/auth_data.yaml" + responses: + 200: + description: The account has been deactivated. + examples: + application/json: "{}" + schema: + type: object + 401: + description: |- + The homeserver requires additional authentication information. + schema: + "$ref": "definitions/auth_response.yaml" + 429: + description: This request was rate-limited. + schema: + "$ref": "definitions/error.yaml" + tags: + - User data diff --git a/changelogs/client_server.rst b/changelogs/client_server.rst index 228ea253..93e329f5 100644 --- a/changelogs/client_server.rst +++ b/changelogs/client_server.rst @@ -1,6 +1,10 @@ ==================== +- Changes to the API which will be backwards-compatible for clients: + + - New endpoints: + - Spec clarifications - Room aliases (`#337 `_): @@ -42,6 +46,9 @@ - ``POST /account/password/email/requestToken`` (`#346 `_). + - ``POST /account/deactivate`` + (`#361 `_). + - Updates to the Presence module (`#278 `_, `#342 `_):