What
SendMessage is the tool agents use to message each other. A teammate is an agent working alongside others in a team. Two new checks can now stop a send.
- Delivery check. Before a message goes out,
SendMessagenow checks that it can be delivered. If it cannot, the send returnssuccess:falsewith a message such as 'Teammate "x" was not messaged', or 'The main conversation was not messaged' when the target is the main conversation. Replies to a known shutdown request are exempt from this check. - Shutdown approval. Approving a shutdown now fails unless the session is running as a teammate. The error reads "Only a teammate can approve a shutdown request, and this session is not running as one. Nothing was sent." and tells the caller to send a
shutdown_requestto the teammate instead. Before, there was no teammate check. - Stopping itself. A teammate running inside the same process that approves a shutdown now stops its own work loop directly, instead of going through the list of running tasks.
The stock SendMessage description in v2.1.304 is 4,259 characters, unchanged since v2.1.303, from a capture taken under this release.
Why
A session that is not a teammate can no longer approve a shutdown and exit itself by mistake. Messages that used to go through can now be refused, and the sender is told plainly that nothing was delivered.