(agentName: string, teamName?: string)
| 54 | * Structure: ~/.claude/teams/{team_name}/inboxes/{agent_name}.json |
| 55 | */ |
| 56 | export function getInboxPath(agentName: string, teamName?: string): string { |
| 57 | const team = teamName || getTeamName() || 'default' |
| 58 | const safeTeam = sanitizePathComponent(team) |
| 59 | const safeAgentName = sanitizePathComponent(agentName) |
| 60 | const inboxDir = join(getTeamsDir(), safeTeam, 'inboxes') |
| 61 | const fullPath = join(inboxDir, `${safeAgentName}.json`) |
| 62 | logForDebugging( |
| 63 | `[TeammateMailbox] getInboxPath: agent=${agentName}, team=${team}, fullPath=${fullPath}`, |
| 64 | ) |
| 65 | return fullPath |
| 66 | } |
| 67 | |
| 68 | /** |
| 69 | * Ensure the inbox directory exists for a team |
no test coverage detected