mirror of
https://github.com/cwinfo/matterbridge.git
synced 2025-03-31 14:53:47 +00:00

* Add support for editing/deleting messages * Add support for uploading files * Add support for avatars * Use the Rocket.Chat.Go.SDK * Use the rest and streaming api
22 lines
455 B
Go
22 lines
455 B
Go
package realtime
|
|
|
|
import "fmt"
|
|
|
|
func (c *Client) StartTyping(roomId string, username string) error {
|
|
_, err := c.ddp.Call("stream-notify-room", fmt.Sprintf("%s/typing", roomId), username, true)
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
return nil
|
|
}
|
|
|
|
func (c *Client) StopTyping(roomId string, username string) error {
|
|
_, err := c.ddp.Call("stream-notify-room", fmt.Sprintf("%s/typing", roomId), username, false)
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
return nil
|
|
}
|