feat(wecom): official aibot long-connection protocol + real WS transport
- wecom_ws.py: AibotWSAdapter (asyncio websockets bridged to channel threads):
connect wss://openws.work.weixin.qq.com, aibot_subscribe auth, 30s ping
heartbeat, reader->queue, graceful shutdown
- wecom.py switched to official frames:
* inbound aibot_msg_callback / aibot_event_callback (enter_chat -> welcome)
* reply: aibot_respond_msg stream {id, finish, content} reusing the
callback's req_id; after finish, proactive aibot_send_msg markdown
* image inbound: {url, aeskey} fetch + AES-256-CBC (IV=key[:16], PKCS7)
* mixed (text+image) and voice (transcribed) message types
- tests updated to official frame shapes; 43 passed
This commit is contained in:
1 parent
62773ab2e5
commit
bbe36be192
6 files changed
+439
-42
No files matched your search
@@ -19,6 +19,7 @@ classifiers = [
|
||||
]
|
||||
dependencies = [
|
||||
"cryptography>=42",
|
||||
"websockets>=12",
|
||||
]
|
||||
|
||||
[project.optional-dependencies]
|
||||
|
||||
Reference in new issue
Block a user