A simple handy tool for wework text msg sending
Project description
pywework
Handy tool for text message sending in Wechat Work
Package pywework is a handy tool for text message in Wechat Work which is compatible with python2.7+ and python3.6+.
User Guild
Configuration file: /etc/wework/wework.cfg
{
"corpid": "",
"app": # App container for real app and room
{
"app01": # app name for WeApp instantiation
{
"agentid": "id01",
"secret": "token01"
},
"room01": # room name for WeApp instantiation
{
"agentid": "id01",
"secret": "token01"
}
},
"party": # party container
{
"default": "0",
"party01": "01" # party name: party
},
"user":
[
"yaochenzhi"
],
"proxies":
{
"http": "http://ip:port",
"https": "http://ip:port"
}
}
Python Code Sample
from pywework import WeApp
app = WeApp("app01")
app.send_app_msg("Hello world to default party in config")
app.send_app_msg("Hello world to only user01", touser="user01")
app.send_app_msg("Hello world to both user01 and user02", touser=["user01", "user02"])
app.close()
app = WeApp("room01")
app.send_room_msg("Hello world")
app.close()
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
pywework-1.0.8-py3-none-any.whl
(423.0 kB
view hashes)