Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Can't get a list of accounts #6922

Closed
csaar95 opened this issue Feb 14, 2020 · 7 comments
Closed

Can't get a list of accounts #6922

csaar95 opened this issue Feb 14, 2020 · 7 comments

Comments

@csaar95
Copy link

csaar95 commented Feb 14, 2020

Description

I'm trying to get all users (see doc), GET /_matrix/client/r0/admin/users returns following error:

{
  "errcode": "M_UNRECOGNIZED",
  "error": "Unrecognized request"
}

GET /_matrix/client/r0/admin/users/[userId] is actually working.

I think this could have sth. to do with following issue #6352.

Steps to reproduce

  • GET /_matrix/client/r0/admin/users

Version information

  • Homeserver: yes

  • Version:

{
  "python_version": "2.7.13",
  "server_version": "1.0.0"
}
{
  "unstable_features": {
    "m.lazy_load_members": true
  },
  "versions": [
    "r0.0.1",
    "r0.1.0",
    "r0.2.0",
    "r0.3.0",
    "r0.4.0",
    "r0.5.0"
  ]
}
  • Install method: pip install https://github.com/matrix-org/synapse/tarball/master

  • Platform: Debian 9.11 (ESX VM)

@richvdh
Copy link
Member

richvdh commented Feb 14, 2020

the endpoint is /_synapse/admin/v2/users, not /_matrix/client/r0/admin/users.

@richvdh richvdh closed this as completed Feb 16, 2020
@csaar95
Copy link
Author

csaar95 commented Feb 17, 2020

I am using the client server api, cause I'm not working on localhost.
Anyway, a GET /_synapse/admin/v2/users on localhost delivers exactly the same error message...

@richvdh
Copy link
Member

richvdh commented Feb 17, 2020

I am using the client server api, cause I'm not working on localhost.

this shouldn't be a problem. /_synapse/admin isn't limited to localhost.

"server_version": "1.0.0"

I think the endpoint you're after was only added recently. You'll need to upgrade.

@csaar95
Copy link
Author

csaar95 commented Feb 17, 2020

Okay, I'll upgrade and let you know if it works.

@csaar95
Copy link
Author

csaar95 commented Feb 19, 2020

Upgraded to

{
    "python_version": "3.5.3",
    "server_version": "1.10.1"
}
  • GET /_synapse/admin/v2/users is now working as expected, thanks:) But not accessible from other clients.
  • GET /_matrix/client/r0/admin/users returns the same errormessage as before.
  • GET /_matrix/client/r0/admin/users/@xxx:yyy.zzz.de actually returns the expected result from GET /_matrix/client/r0/admin/users!?

@richvdh
Copy link
Member

richvdh commented Feb 19, 2020

GET /_matrix/client/r0/admin/users/@xxx:yyy.zzz.de actually returns the expected result from GET /_matrix/client/r0/admin/users!?

I don't know what the expected result is. It's not a documented API, and one of the reasons we introduced GET /_synapse/admin/v2/users is that the existing /_matrix/client/r0/admin/users didn't have a sensible interface (see also #2522).

You should use GET /_synapse/admin/v2/users.

@csaar95
Copy link
Author

csaar95 commented Feb 20, 2020

I don't know what the expected result is.

It delivers, the same result as GET /_synapse/admin/v2/users.
I'll set up a proxy referring to localhost:8008, so it's possible to use /_synapse/admin. Thanks.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants