#6588: feat(channels): add 'confirming' dmPolicy mode for owner-approved responses
channel: whatsapp-web
cli
Cluster:
WhatsApp Pairing Enhancements
## Summary
Adds a new `dmPolicy: "confirming"` mode that sits between `open` and `pairing`. In this mode:
- The agent **receives and processes** the message
- The agent **generates a suggested response**
- The response is **sent to the owner for approval** instead of directly to the sender
- Only after owner approval is the response sent
## Configuration
```json
{
"channels": {
"whatsapp": {
"dmPolicy": "confirming",
"confirming": {
"ownerChat": "554788703000@s.whatsapp.net",
"timeout": 3600,
"onTimeout": "queue"
}
}
}
}
```
## CLI Commands
- `openclaw confirming list whatsapp` - List pending responses
- `openclaw confirming approve whatsapp <code>` - Approve and send
- `openclaw confirming edit whatsapp <code> "message"` - Approve with edit
- `openclaw confirming reject whatsapp <code>` - Reject (no message sent)
## Use Case
Essential for:
- Personal assistants managing client communications
- Small businesses wanting AI help but needing final approval
- Anyone who wants to leverage AI suggestions without losing control
Fixes #6262
<!-- greptile_comment -->
<h2>Greptile Overview</h2>
<h3>Greptile Summary</h3>
This PR introduces a new `dmPolicy: "confirming"` flow intended to generate an AI response but route it to an owner for approval before sending to the original sender. It adds:
- A new `confirming` CLI (`openclaw confirming ...`) for listing/approving/rejecting pending responses.
- Config/types + zod schema support for `dmPolicy: "confirming"` and `channels.whatsapp.confirming` settings.
- A simple on-disk pending-response store (`src/confirming/confirming-store.ts`) plus message builders.
- WhatsApp inbound integration that creates pending responses and sends an owner notification + sender acknowledgement.
In the current wiring, the confirming-mode access-control logic appears inconsistent with the intended semantics (it doesn’t reliably enable confirming mode and the allowlist check compares normalized values against un-normalized ids), so the feature may not behave as expected without follow-up fixes.
<h3>Confidence Score: 2/5</h3>
- This PR is not yet safe to merge because the core confirming-mode gating logic likely doesn’t behave as intended in production.
- Score reduced due to a likely functional bug in WhatsApp inbound access-control that prevents `dmPolicy: "confirming"` from reliably triggering, plus an ID normalization mismatch that can block allowlisted senders. Remaining issues are smaller correctness/UX concerns around what message is stored/shown and where approved replies are sent.
- src/web/inbound/access-control.ts, src/web/inbound/monitor.ts, src/cli/confirming-cli.ts
<!-- greptile_other_comments_section -->
<!-- /greptile_comment -->
Most Similar PRs
#6265: feat(whatsapp): add pairing owner notification
by zote · 2026-02-01
82.1%
#14789: fix: per-account dmPolicy ignored in checkInboundAccessControl
by croll83 · 2026-02-12
79.2%
#11611: feat: separate group-level allowlist from sender-level command auth...
by thisnick · 2026-02-08
78.0%
#11249: fix(whatsapp): prevent pairing-mode auto-replies to unknown DMs
by liuxiaopai-ai · 2026-02-07
77.4%
#17882: fix: drop WhatsApp pairing reply for unconfigured accounts
by adit-negi · 2026-02-16
77.0%
#6567: fix: include paired users in WhatsApp group sender allowlist
by giannisanni · 2026-02-01
76.3%
#21889: fix(whatsapp): include outbound DMs in agent context for allowed co...
by mactsk · 2026-02-20
75.5%
#4402: fix: store group messages from non-allowlisted senders as pending c...
by adam91holt · 2026-01-30
75.5%
#21893: fix(web): enforce sendPolicy on WhatsApp auto-reply delivery path
by hydro13 · 2026-02-20
73.6%
#7911: Unapproved users receive pairing codes on every /start message befo...
by crazypeace · 2026-02-03
73.4%