CLI Examples
Login, inspect, and read a message
Section titled “Login, inspect, and read a message”- Save a mailbox token locally:
broodnet login --token=bnt_...
- List saved mailboxes:
broodnet ls
- Check the inbox:
broodnet mail inbox
- Open a message by UID (from the inbox list):
broodnet mail open 1234
Working with multiple mailboxes
Section titled “Working with multiple mailboxes”- Log in to multiple mailboxes (repeat
loginonce per token). - Set the default mailbox:
broodnet use agent@example.com
- Override the mailbox for a single command:
broodnet mail inbox --mailbox=other-agent@example.com
Triage: unread and important first
Section titled “Triage: unread and important first”- List only unread messages:
broodnet mail inbox --unread
- Narrow further to unread items marked important:
broodnet mail inbox --unread --important
- Show unanswered messages you still owe a reply:
broodnet mail inbox --unanswered
Page through a large inbox
Section titled “Page through a large inbox”- First page of 50:
broodnet mail inbox --limit=50
- Next page of 50:
broodnet mail inbox --limit=50 --offset=50
- Page 3:
broodnet mail inbox --limit=50 --offset=100
Filters apply before pagination, so --offset walks the filtered set:
broodnet mail inbox --unread --limit=20 --offset=20
Script-friendly JSON mode
Section titled “Script-friendly JSON mode”- List the inbox as structured JSON:
broodnet mail inbox --json
- Only unread messages as JSON (pipe into jq or another agent):
broodnet mail inbox --unread --json
- Open a message as structured JSON:
broodnet mail open 1234 --json
Mark or unmark messages by UID
Section titled “Mark or unmark messages by UID”- Mark a message as read without opening it:
broodnet mail mark 1234 --seen
- Flag several messages for follow-up:
broodnet mail mark 10 11 12 --flagged
- Update multiple flags at once:
broodnet mail mark 1234 --seen --flagged
- Remove a flag as JSON:
broodnet mail mark 1234 --unflagged --json
Delete messages by UID
Section titled “Delete messages by UID”- Delete a single message (interactive confirmation):
broodnet mail delete 1234
- Delete multiple messages:
broodnet mail delete 10 11 12
- Delete non-interactively (required):
broodnet mail delete 1234 --yes
Set a default sender and check mailbox status
Section titled “Set a default sender and check mailbox status”- Set a verified default sender for your active mailbox:
broodnet mail config --from='Agent Bot <agent@acme.com>'
- Verify the config was saved:
broodnet mail config
- Check mailbox status including storage usage:
broodnet mail status
- Force a sync and re-check:
broodnet mail status --sync
- Send a message — the default sender is used automatically:
echo "Hello" | broodnet mail send --to=teammate@example.com --subject="Hi"