diff --git a/lib/src/Room.dart b/lib/src/Room.dart index cacdd89d..26a4a14c 100644 --- a/lib/src/Room.dart +++ b/lib/src/Room.dart @@ -974,6 +974,18 @@ class Room { data: data); return resp; } + + Future sendTypingInfo(bool isTyping, {int timeout}) { + Map data = { + "typing": isTyping, + }; + if (timeout != null) data["timeout"] = timeout; + return client.connection.jsonRequest( + type: HTTPType.PUT, + action: "/client/r0/rooms/${this.id}/typing/${client.userID}", + data: data, + ); + } } enum PushRuleState { notify, mentions_only, dont_notify }