mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2025-01-26 20:21:40 +01:00
Add setProfileAvatarURl and displayName
This commit is contained in:
parent
96f58327ee
commit
46230e59ad
@ -302,6 +302,14 @@ export class HomeServerApi {
|
||||
return this._get(`/profile/${encodeURIComponent(userId)}`);
|
||||
}
|
||||
|
||||
setProfileDisplayName(userId, displayName, options?: BaseRequestOptions): IHomeServerRequest {
|
||||
return this._put(`/profile/${encodeURIComponent(userId)}/displayname`, {}, { displayname: displayName }, options);
|
||||
}
|
||||
|
||||
setProfileAvatarUrl(userId, avatarUrl, options?: BaseRequestOptions): IHomeServerRequest {
|
||||
return this._put(`/profile/${encodeURIComponent(userId)}/avatar_url`, {}, { avatar_url: avatarUrl }, options);
|
||||
}
|
||||
|
||||
createRoom(payload: Record<string, any>, options?: BaseRequestOptions): IHomeServerRequest {
|
||||
return this._post(`/createRoom`, {}, payload, options);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user