Query for profile information about a given user

GET {{baseUrl}}/query/profile?user_id=@someone:example.org&field=avatar_url

Performs a query to get profile information, such as a display name or avatar, for a given user. Homeservers should only query profiles for users that belong to the target server (identified by the DNS Name in the user ID).

Servers may wish to cache the response to this query to avoid requesting the information too often.

Request Params

KeyDatatypeRequiredDescription
user_idstring(Required) The user ID to query.
fieldstringThe field to query. If specified, the server will only return the given field
in the response. If not specified, the server will return the full profile for
the user.

RESPONSES

status: OK

{"displayname":"John Doe","avatar_url":"mxc://matrix.org/MyC00lAvatar"}