Add setProfileAvatarURl and displayName
This commit is contained in:
parent
96f58327ee
commit
46230e59ad
1 changed files with 8 additions and 0 deletions
|
@ -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);
|
||||
}
|
||||
|
|
Reference in a new issue