Skip to content

Conversation

@hughns
Copy link
Member

@hughns hughns commented Oct 17, 2025

Rendered


I am employed by Element to write this MSC. Hence the use of the io.element namespace in the unstable values.

@hughns hughns changed the title M_CAPABILITY_NOT_ENABLED error code for when capability is not enabled on an API endpoint MSC4369: M_CAPABILITY_NOT_ENABLED error code for when capability is not enabled on an API endpoint Oct 17, 2025
@turt2live turt2live added proposal A matrix spec change proposal client-server Client-Server API kind:maintenance MSC which clarifies/updates existing spec needs-implementation This MSC does not have a qualifying implementation for the SCT to review. The MSC cannot enter FCP. hacktoberfest-accepted labels Oct 17, 2025
@hughns hughns requested a review from anoadragon453 October 22, 2025 14:47
@hughns hughns marked this pull request as ready for review October 22, 2025 14:49

## Proposal

Define a new [other error code] of `M_CAPABILITY_NOT_ENABLED`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there any value in having a specific error code for this? Clients should already know which endpoint is behind a capability, so M_FORBIDDEN should work just as well.

Actually I am wondering if instead of returning 403, it wouldn't be simpler to return 404 with M_UNRECOGNIZED, as if the endpoint is unimplemented?

This means that the endpoint doesn't actually have to be implemented by the homeserver if it doesn't support this capability (like POST /_matrix/client/v3/account/password which is useless if the homeserver only supports the OAuth 2.0 API for authentication), rather than forcing the homeserver to support this endpoint, only to return a specific error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

client-server Client-Server API hacktoberfest-accepted kind:maintenance MSC which clarifies/updates existing spec needs-implementation This MSC does not have a qualifying implementation for the SCT to review. The MSC cannot enter FCP. proposal A matrix spec change proposal

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants