MCPcopy Create free account
hub / github.com/smallfawn/QLScriptPublic / send_text

Method send_text

daily/notify.py:531–545  ·  view source on GitHub ↗
(self, message, touser="@all")

Source from the content-addressed store, hash-verified

529 return data["access_token"]
530
531 def send_text(self, message, touser="@all"):
532 send_url = (
533 f"{self.ORIGIN}/cgi-bin/message/send?access_token={self.get_access_token()}"
534 )
535 send_values = {
536 "touser": touser,
537 "msgtype": "text",
538 "agentid": self.AGENTID,
539 "text": {"content": message},
540 "safe": "0",
541 }
542 send_msges = bytes(json.dumps(send_values), "utf-8")
543 respone = requests.post(send_url, send_msges)
544 respone = respone.json()
545 return respone["errmsg"]
546
547 def send_mpnews(self, title, message, media_id, touser="@all"):
548 send_url = (

Callers 1

wecom_appFunction · 0.95

Calls 2

get_access_tokenMethod · 0.95
postMethod · 0.45

Tested by

no test coverage detected