inbox
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseInbox - Read Inter-Agent Messages
收件箱 - 读取代理间消息
Check and read messages sent to this session's inbox from other agents or sessions.
查看和读取从其他代理或会话发送到本次会话收件箱的消息。
When to Use
适用场景
- Another agent mentions sending a message
- Starting work on a task that may have been handed off
- Coordinating with other Claude sessions
- Checking for pending messages or recent communications
- 其他代理提及已发送消息
- 开始处理可能已移交的任务
- 与其他Claude会话协作
- 检查待处理消息或近期通信
How It Works
工作原理
Each hive session has a unique inbox topic (). Other agents publish messages to this inbox, readable via the commands below.
agent.<id>.inboxBy default, messages are NOT marked as read. Use to acknowledge messages.
--ack每个hive会话都有一个唯一的收件箱主题()。其他代理会将消息发布到该收件箱,可通过以下命令读取。
agent.<id>.inbox默认情况下,消息不会被标记为已读。使用参数可确认消息。
--ackCommands
命令
Read Unread Messages (Default)
读取未读消息(默认)
bash
hive msg inboxShows unread messages without marking them as read.
bash
hive msg inbox显示未读消息且不标记为已读。
Read and Acknowledge
读取并确认
bash
hive msg inbox --ackShows unread messages and marks them as read so they won't appear again.
bash
hive msg inbox --ack显示未读消息并将其标记为已读,使其不会再次显示。
Read All Messages
读取所有消息
bash
hive msg inbox --allShows all messages (read and unread).
bash
hive msg inbox --all显示所有消息(已读和未读)。
Specify Session Explicitly
显式指定会话
bash
hive msg inbox --session <id|name>Overrides auto-detection from working directory. Useful when running outside a session directory.
bash
hive msg inbox --session <id|name>覆盖从工作目录自动检测的会话。在会话目录外运行时非常有用。
Wait for a Message
等待消息
bash
hive msg inbox --wait
hive msg inbox --wait --timeout 2mBlocks until a message arrives. Default timeout is 24h for wait mode.
bash
hive msg inbox --wait
hive msg inbox --wait --timeout 2m阻塞直到消息到达。等待模式下的默认超时时间为24小时。
Poll for New Messages
轮询新消息
bash
hive msg inbox --listen --timeout 30sContinuously polls and outputs new messages until timeout.
bash
hive msg inbox --listen --timeout 30s持续轮询并输出新消息,直到超时。
Limit Results
限制结果数量
bash
hive msg inbox --tail 5Returns only the last N unread messages.
bash
hive msg inbox --tail 5仅返回最后N条未读消息。
Output Format
输出格式
All output is JSON Lines (one JSON object per line) on stdout. Fields:
- - Unique message identifier
id - - The inbox topic (
topic)agent.<id>.inbox - - The message text
payload - - Who sent the message (session ID or custom sender)
sender - - Sender's session ID (if auto-detected)
session_id - - ISO 8601 timestamp
created_at
On timeout (/), a JSON status line is printed and exit code is 1.
--listen--wait所有输出以JSON Lines格式(每行一个JSON对象)输出到标准输出。字段包括:
- - 唯一消息标识符
id - - 收件箱主题(
topic)agent.<id>.inbox - - 消息文本
payload - - 消息发送方(会话ID或自定义发送方)
sender - - 发送方的会话ID(若自动检测到)
session_id - - ISO 8601时间戳
created_at
超时(/)时,会打印一条JSON状态行,退出码为1。
--listen--waitCommon Workflows
常见工作流
Basic Message Check
基本消息检查
bash
hive msg inboxRead and act on any unread messages.
bash
hive msg inbox读取并处理所有未读消息。
Handle Coordinated Handoff
处理协作移交
When another agent hands off work:
bash
undefined当其他代理移交工作时:
bash
undefinedCheck inbox for handoff message
检查收件箱中的移交消息
hive msg inbox
hive msg inbox
Read referenced task details
读取相关任务详情
bd show <issue-id>
undefinedbd show <issue-id>
undefinedReview Message History
查看消息历史
bash
hive msg inbox --allbash
hive msg inbox --allAdditional Resources
额外资源
For troubleshooting and advanced usage patterns, see:
- - Common issues and solutions
references/troubleshooting.md
有关故障排除和高级使用模式,请参阅:
- - 常见问题及解决方案
references/troubleshooting.md
Related Skills
相关技能
- - Send messages to other agents
/hive:publish - - Wait for specific messages with timeout
/hive:wait - - Get current session details and inbox topic
/hive:session-info
- - 向其他代理发送消息
/hive:publish - - 等待特定消息并设置超时
/hive:wait - - 获取当前会话详情和收件箱主题
/hive:session-info