From e57b75a19a8f4a02bf93e99ac9dbf3c06575b219 Mon Sep 17 00:00:00 2001 From: Matias Linares Date: Sun, 28 Mar 2021 19:51:16 -0300 Subject: Add typing api support --- lib/Matrix/Client/Room.rakumod | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'lib/Matrix/Client/Room.rakumod') diff --git a/lib/Matrix/Client/Room.rakumod b/lib/Matrix/Client/Room.rakumod index 34c73ae..1a6908f 100644 --- a/lib/Matrix/Client/Room.rakumod +++ b/lib/Matrix/Client/Room.rakumod @@ -153,7 +153,15 @@ method read-marker(Str:D $fully-read, Str $read?) { $.post('/read_markers', |%data); } -method typing() +#| PUT - /_matrix/client/r0/rooms/{roomId}/typing/{userId} +method typing(Bool $typing, Str :$user-id!, Int :$timeout) { + my %data = :$typing; + + %data = $timeout with $timeout; + $.put( + "/typing/{$user-id}", |%data + ); +} # Room membership! -- cgit v1.2.3-70-g09d2