refactor: methods for mute/unmute chat added
This commit is contained in:
parent
2fab5ae9c4
commit
bfac7c57e1
|
@ -63,4 +63,12 @@ proc sendImages*(chatId: string, images: var seq[string]): RpcResponse[JsonNode]
|
|||
"text": "Update to latest version to see a nice image here!"
|
||||
}
|
||||
)
|
||||
callPrivateRPC("sendChatMessages".prefix, %* [imagesJson])
|
||||
callPrivateRPC("sendChatMessages".prefix, %* [imagesJson])
|
||||
|
||||
proc muteChat*(chatId: string): RpcResponse[JsonNode] {.raises: [Exception].} =
|
||||
let payload = %* [chatId]
|
||||
result = callPrivateRPC("muteChat".prefix, payload)
|
||||
|
||||
proc unmuteChat*(chatId: string): RpcResponse[JsonNode] {.raises: [Exception].} =
|
||||
let payload = %* [chatId]
|
||||
result = callPrivateRPC("unmuteChat".prefix, payload)
|
Loading…
Reference in New Issue