Repository navigation
feat(automations): tell a person in their own chat app, the notify action - #433
Merged
Merged
Conversation
…tion An automation can now tell someone something. Each chat channel keeps the private chat it last had with someone on its list of people who may talk to Lens (chat_route), and channels.tell sends there, as the account the bot or app answers as. The notify action uses it for "me" (routine: only they read it) and also sends to a namespace's notification target or a Matterbridge gateway, which reach other people and so ask first. Links an injection could fill are broken up when the run read outside text. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CyjR2zEfmTXBewKAx9Taw5
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CyjR2zEfmTXBewKAx9Taw5
This was referenced Oct 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Requested by Adeel · project thread
Description
Before: automations had one action,
log_line, and Lens had no way to message a person unprompted: a chat channel could only reply to a message it had just received.After: the
notifyaction (workflow studio M7, first group: Messages) sends a message to one of three places:me: the automation's own person, in their chat app. Each chat channel now keeps the private chat it last had with someone on its list of people who may talk to Lens (chat_route:<channel>), andchannels.tell(db, cfg, account, text, links=())sends there through every channel that answers as that account. Effectself, so it runs without asking.target:<id>: one of the namespace's notification targets (webhook, Matterbridge, Slack, Discord), throughnotify.send.gateway:<name>: a Matterbridge room, through the bridge.The last two reach other people, so their effect is
outand they ask first unless the person set that node to run on its own.drysays where it would go and sends nothing. The result names each channel and chat used, so M8 can match a "yes" there to an approval.Motivation and Context
Workflow studio, module M7 (plan:
/mnt/project-files/workflow-studio/plan.md§5 M7). This is the "tell me in Telegram" step of the worked example; the other action groups (AI, web, Lens work, assets) follow in their own PRs.Choices taken (reversible), differing from the brief's wording:
userslist. So a route is kept only for a private chat (Telegram private chat, Slack DM) whose sender is on the channel'suserslist, and is re-checked when sending. Matterbridge never counts as private (its gateways are rooms);gateway:<name>reaches it and asks first.untrustedis set (the run read outside text), web addresses are broken up (hxxps://evil[.]example/...) except Lens's own; when it read none, the person wrote them and they stay. This usesbridge.safe_linksanduntrusted.defang.actions.person(db, intent, user)gives the account an intent acts for, as it is now. A switched-off or removed person makes every action refuse.Types of changes
!in the title)Checklist:
tests/api/test_actions_messages.py: routes kept only for vouched private chats, latest wins, re-checked on send; Telegram and Slack; notify to me, a webhook target and a Matterbridge gateway; dry runs; risk; links broken up or kept).docs/accordingly (docs/automations.mdActions table and "Telling a person",docs/chat-rooms.md"Telling you things").Done questions (AGENTS.md)
actions.catalog(), which M6 serves atGET /api/v1/automations/actionsand to MCP and the assistant.chat.<channel>).outand asks first; defaults unchanged.chat_route), no change to stored data.docs/automations.md: chat approval buttons, email and web push as channels, private chats through Matterbridge, "me" with several people let in, which template links to keep.🤖 Generated with Claude Code
https://claude.ai/code/session_01CyjR2zEfmTXBewKAx9Taw5
Generated by Claude Code