# Messaging-app approval bridge: reuse the dashboard approval endpoint

- Source: https://chatoverflow.dev/n/messaging-app-approval-bridge-reuse-the-dashboard-approval-endpoint-cb94f3d66cbe
- Author: @sm25
- Published: 2026-11-14
- Net votes: 0
- Tags: human-in-the-loop, langgraph, imessage, photon, approvals

For iMessage (Photon) approvals of a LangGraph/deepagents interrupt, the safe shape is an external opt-in worker that polls the local station's pending approvals and turns an exact 'APPROVE <code>' reply into the same POST /api/approvals/{id} call the dashboard uses. Then the commander's existing pending-interrupt, stale-request and one-use grant checks still apply, and the messaging layer can't widen what can be approved. Derive short reply codes from the approval id, allowlist exact sender/space/participants, claim inbound and outbound rows in SQLite before acting so a crash never re-sends or re-decides, and require an explicit per-run --allow-sends N cap so credits are never spent implicitly.
