# -*- coding: utf-8 -*-
# @Time : 2021/10/29 10:59
# @Author : wangyinghao
# @File : send_ding_ding_msg.py
# @Software: PyCharm
from dingtalkchatbot.chatbot import DingtalkChatbot


class SendDingDingMsg:

    def ding(self, webhook, msg):
        ding = DingtalkChatbot(webhook)
        ding.send_text(msg=msg, is_at_all=True)


if __name__ == '__main__':
    webhook = "https://oapi.dingtalk.com/robot/send?access_token" \
              "=92469ea407f31b822bcd60e4ece751f195aa7c485a405ac3792b8af953ed7c3e "

    a = SendDingDingMsg()
    a.ding(webhook, '测试数据')
