add helper for sending m.notice
This commit is contained in:
parent
6ddad07136
commit
4ad25be512
1 changed files with 9 additions and 0 deletions
|
|
@ -48,3 +48,12 @@ class SMALBot(SMALApp):
|
||||||
data["content"]["m.relates_to"]["m.in_reply_to"]["event_id"] = msgid
|
data["content"]["m.relates_to"]["m.in_reply_to"]["event_id"] = msgid
|
||||||
|
|
||||||
self._sendmessage(data)
|
self._sendmessage(data)
|
||||||
|
|
||||||
|
def sendnotice(self, roomid, text):
|
||||||
|
data = {}
|
||||||
|
data["roomid"] = roomid
|
||||||
|
data["content"] = {}
|
||||||
|
data["content"]["body"] = text
|
||||||
|
data["content"]["msgtype"] = "m.notice"
|
||||||
|
|
||||||
|
self._sendmessage(data)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue