curl -sS 'https://matrix.example.com/_synapse/admin/v2/users/@alice:example.com' -H "Authorization: Bearer $ACCESS_TOKEN"

Category: Matrix & Synapse

curl -sS 'https://matrix.example.com/_synapse/admin/v2/users/@alice:example.com' -H "Authorization: Bearer $ACCESS_TOKEN"

Fetch details of one Matrix user

Returns the account record for @alice:example.com: display name, admin flag, deactivated state, creation time, and linked email or phone IDs. An access token is the secret string from an admin user's account (Element: Settings, Help & About) that authorizes Admin API calls; export ACCESS_TOKEN='syt_...' in your shell so the header expands. The URL encodes the user ID as-is, including the @ sign. Server admins differ from room admins.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.