mirror of
https://github.com/hansjone/oclaw.git
synced 2026-10-10 05:10:45 +08:00
feat(whatsapp): add access control with quote-based admin approval
Introduce whitelist/blacklist gating, pending requests, Admin UI management, and stanza-mapped quote approval so admins can approve via WhatsApp DM without blocking normal LLM chat. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
8781a200c9
commit
1ea13a205d
13 changed files with 3048 additions and 30 deletions
|
|
@ -48,6 +48,12 @@ def test_whatsapp_runner_supports_reply_attachments_base64() -> None:
|
|||
assert "media_url" in text
|
||||
|
||||
|
||||
def test_whatsapp_runner_resolves_dm_remote_jid_alt() -> None:
|
||||
text = _read("runtime/operations/whatsapp_bridge/baileys_runner.ts")
|
||||
assert "resolveDmUserJid" in text
|
||||
assert "remoteJidAlt" in text
|
||||
|
||||
|
||||
def test_whatsapp_runner_supports_inbound_media_download() -> None:
|
||||
text = _read("runtime/operations/whatsapp_bridge/baileys_runner.ts")
|
||||
assert "downloadMediaMessage" in text
|
||||
|
|
@ -58,3 +64,9 @@ def test_whatsapp_runner_supports_inbound_media_download() -> None:
|
|||
assert "buildOutboundMediaMessage" in text
|
||||
assert "video_base64" in text
|
||||
assert "audio_base64" in text
|
||||
|
||||
|
||||
def test_whatsapp_runner_outbound_ack_passes_stanza_id() -> None:
|
||||
text = _read("runtime/operations/whatsapp_bridge/baileys_runner.ts")
|
||||
assert "stanza_id" in text
|
||||
assert "sent as any)?.key?.id" in text
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue