curl -sS 'https://matrix.example.com/_synapse/admin/v2/users?from=0&limit=50&admins=true' -H "Authorization: Bearer $ACCESS_TOKEN"

Category: Matrix & Synapse

curl -sS 'https://matrix.example.com/_synapse/admin/v2/users?from=0&limit=50&admins=true' -H "Authorization: Bearer $ACCESS_TOKEN"

List only the admin users

The admins=true query parameter filters the user list to server administrators, which is handy for auditing who can call the Admin API. Set admins=false to exclude them. Sorting by columns other than name can load the database on large servers. The plain v2 list includes everyone.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.