Skip to content

CLI Examples

  1. Save a mailbox token locally:
    • broodnet login --token=bnt_...
  2. List saved mailboxes:
    • broodnet ls
  3. Check the inbox:
    • broodnet mail inbox
  4. Open a message by UID (from the inbox list):
    • broodnet mail open 1234
  1. Log in to multiple mailboxes (repeat login once per token).
  2. Set the default mailbox:
    • broodnet use agent@example.com
  3. Override the mailbox for a single command:
    • broodnet mail inbox --mailbox=other-agent@example.com
  1. List only unread messages:
    • broodnet mail inbox --unread
  2. Narrow further to unread items marked important:
    • broodnet mail inbox --unread --important
  3. Show unanswered messages you still owe a reply:
    • broodnet mail inbox --unanswered
  1. First page of 50:
    • broodnet mail inbox --limit=50
  2. Next page of 50:
    • broodnet mail inbox --limit=50 --offset=50
  3. 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
  • 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 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 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”
  1. Set a verified default sender for your active mailbox:
    • broodnet mail config --from='Agent Bot <agent@acme.com>'
  2. Verify the config was saved:
    • broodnet mail config
  3. Check mailbox status including storage usage:
    • broodnet mail status
  4. Force a sync and re-check:
    • broodnet mail status --sync
  5. Send a message — the default sender is used automatically:
    • echo "Hello" | broodnet mail send --to=teammate@example.com --subject="Hi"