Skip to main content

企业微信WorkTool机器人API的封装。

Project description

这只是 WorkTool API 的简单封装,以便于能够在各种程序中引入复用。

可以参考 WorkTool的API文档,但部分功能尚未封装。

已封装的功能

  • 发送文本
  • 发送图片/文件/音频/视频/其他

使用示例

安装模块

pip install wecom_worktool

import worktool

with worktool.Worktool("your_robot_id") as bot:
        bot.send_file(
            ["群1", "好友1"],
            "文件名.jpg",
            "https://your_image_url.jpg",
            bot.FileType.IMAGE
        )
        bot.send_text(
            ["好友1"],
            "Hello world!"
        )
        bot.send_text(
            ["群1"],
            "Hello world!",
            ["@所有人"]
        )

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wecom_worktool-0.0.3.tar.gz (2.3 kB view hashes)

Uploaded Source

Built Distribution

wecom_worktool-0.0.3-py3-none-any.whl (2.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page