MCPcopy Create free account
hub / github.com/Noumena-Network/code / sendMessageToLeader

Function sendMessageToLeader

src/utils/swarm/inProcessRunner.ts:548–564  ·  view source on GitHub ↗

* Sends a message to the leader's file-based mailbox. * Uses the same mailbox system as tmux teammates for consistency.

(
  from: string,
  text: string,
  color: string | undefined,
  teamName: string,
)

Source from the content-addressed store, hash-verified

546 * Uses the same mailbox system as tmux teammates for consistency.
547 */
548async function sendMessageToLeader(
549 from: string,
550 text: string,
551 color: string | undefined,
552 teamName: string,
553): Promise<void> {
554 await writeToMailbox(
555 TEAM_LEAD_NAME,
556 {
557 from,
558 text,
559 timestamp: new Date().toISOString(),
560 color,
561 },
562 teamName,
563 )
564}
565
566/**
567 * Sends idle notification to the leader via file-based mailbox.

Callers 1

sendIdleNotificationFunction · 0.85

Calls 1

writeToMailboxFunction · 0.85

Tested by

no test coverage detected