matrix-org / matrix-org/matrix-spec

Distinction between deleting devices and invalidating access tokens is bogus and confusing

Open
#1,950 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

improvement
Dominant language
HTML
Stars
330
Forks
150
Avg merge
2h 21m
Merged PRs (30d)
3

Description

Suggestion

The difference between "deleting a device" (via https://spec.matrix.org/v1.11/client-server-api/#post_matrixclientv3delete_devices) and "logging out an access token" (via e.g. https://spec.matrix.org/v1.11/client-server-api/#post_matrixclientv3logout) is not terribly clear. After some discussion in #matrix-spec, it appears there is no difference, since:

  • /logout* invalidates the access token but also deletes the associated device
  • /delete_devices deletes the devices but also invalidates their access tokens

So essentially the same operation is approached from two different angles: one from the perspective of deleting a device (and invalidating all of its access tokens) and the other from the perspective of invalidating an access token (and deleting its device and other access tokens).

This makes /delete_devices a weird odd beast. It would make more sense to have a /logout/some instead.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the linked Matrix Client-Server API sections for POST /_matrix/client/v3/delete_devices and /logout, then review the linked #matrix-spec discussion. Determine whether the operations should be distinguished or unified in the specification; done means the relevant endpoint descriptions and rationale consistently explain the chosen behavior.

Written by the indexing model from the issue text.

Assessment

Domain
api, documentation
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.