MCPcopy Index your code
hub / github.com/codeaashu/claude-code / sendMessageToLeader

Function sendMessageToLeader

src/utils/swarm/inProcessRunner.ts:547–563  ·  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

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