Owner Questions on a Connection
A connection tells Link which of its chats are the owner's own, so the agent's bridge can ask the owner there what only they can answer. The owner's reply with the question's code is caught before the agent.
lnk-<connection> owner
A connection with chats Link can ask the owner on (lnk-telegram,
lnk-slack, lnk-discord, lnk-signal) answers owner. It reads the
Bridge as one JSON line on stdin, as bridge does, and prints a JSON
array of the owner's direct chats, each as its thread names it after the
connection: telegram:42's 42.
Which chats they are
Telegram's are each allowed user's own chat with the bot, whose id is
theirs, and Signal's each allowed number's, its digits. Slack's and
Discord's are the owner's direct conversation with the bot,
dm_channel, which connect saves; one connected before Link kept it
has none until it's connected again.
A connection without it
A connection that doesn't answer owner, or names no chat, is asked on
by none: the owner answers its agent's questions another way, such as a
dialog or lnk sandbox answer.
A reply that answers
Every owner's message a bridge carries passes one function of the
contract (link_connection_contract::questions::caught) before it
reaches the harness. A message that is a question's code alone, or no
and its code, on a chat the question was asked on, answers it there:
the bridge shows what the contract answers (Allowed, once.,
Refused.), and the harness never sees it. Any other message is the
agent's.
While a turn is under way
The same function records each owner's turn on its chat while the harness answers it, so the agent's bridge asks that turn's questions where the owner is. A message joining a running turn is caught first, so a code typed while the turn waits for its answer never steers it.