Drive your personal Microsoft 365 inbox from agents โ read, send, sync, and run offline triage analytics that... Trigger phrases: `what's in my inbox`, `find emails from X`, `send an outlook email`, `follow up on email I sent`, `stale unread in outlook`, `who's emailing me most`, `use outlook-email`, `run outlook-email`.
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
A direct command skips the review prompt. Inspect the source before running it.
Drive your personal Microsoft 365 inbox from agents โ read, send, sync, and run offline triage analytics that... Trigger phrases: `what's in my inbox`, `find emails from X`, `send an outlook email`, `follow up on email I sent`, `stale unread in outlook`, `who's emailing me most`, `use outlook-email`, `run outlook-email`.
This skill drives the outlook-email-pp-cli binary. You must verify the CLI is installed before invoking any command from this skill. If it is missing, install it first:
Install via the Printing Press installer. It defaults binaries to $HOME/.local/bin on macOS/Linux and %LOCALAPPDATA%\Programs\PrintingPress\bin on Windows:
Ensure the reported install directory is on $PATH for the agent/runtime that will invoke this skill.
If the npx install fails (no Node, offline, etc.), fall back to a direct Go install (requires Go 1.26.5 or newer):
go install github.com/mvanhorn/printing-press-library/library/productivity/outlook-email/cmd/outlook-email-pp-cli@latest
If --version reports "command not found" after install, the runtime cannot see the binary directory on $PATH. Do not proceed with skill commands until verification succeeds.
When to Use This CLI
Reach for this CLI when an agent needs to triage a personal Microsoft 365 inbox at scale, surface follow-ups, or compose mail without a Copilot license. It is the right choice over generic HTTP because the offline store unlocks cross-folder/cross-time queries (followup, senders, waiting, digest) that require persisted state.
Unique Capabilities
These capabilities aren't available in any other tool for this API.
Local state that compounds
followup โ List emails you sent more than N days ago that the recipient never replied to โ close the loops you forgot about.
Sales, PM, and recruiting workflows live and die on follow-up timing. Reach for this when an agent needs to surface stalled threads.
outlook-email-pp-cli followup --days 7 --agent
senders โ Group your inbox by sender over a window: count, unread, last-received, dominant folder โ see who's drowning your inbox.
Use as the input to bulk-archive or to drive inbox-rule decisions. Agents pruning a flooded inbox start here.
rules โ Inbox rules that automatically process incoming messages
outlook-email-pp-cli rules create โ Create an inbox rule
outlook-email-pp-cli rules delete โ Delete an inbox rule
outlook-email-pp-cli rules get โ Get a single inbox rule
outlook-email-pp-cli rules list โ List inbox rules
outlook-email-pp-cli rules update โ Update an inbox rule
send_mail โ Send a brand-new email in one shot (skips the drafts folder)
outlook-email-pp-cli send_mail โ Compose and send a message without first saving to drafts
Finding the right command
When you know what you want to do but not which command does it, ask the CLI directly:
outlook-email-pp-cli which"<capability in your own words>"
which resolves a natural-language capability query to the best matching command from this CLI's curated feature index. Exit code 0 means at least one match; exit code 2 means no confident match โ fall back to --help or use a narrower query.
Recipes
Morning catchup
outlook-email-pp-cli sync && outlook-email-pp-cli since 12h --agent --select sender,subject,inference_classification,received_at
Delta-sync the mailbox, then surface only what landed overnight, grouped for an agent to summarize.
Reads a sender list from senders.txt (one address per line), resolves matching messages in the local store, and prints the move plan. Pass --execute to actually call POST /me/messages/{id}/move per id.
Auth Setup
OAuth 2.0 device-code flow against https://login.microsoftonline.com/common. Personal MSAs (Outlook.com, Hotmail, Live) work alongside work/school accounts. Default client id is the Microsoft Graph PowerShell app, so no Azure tenant is needed. BYO Azure AD app via --client-id. Refresh tokens persisted at ~/.config/outlook-email-pp-cli/config.toml; run auth refresh or let commands auto-rotate.
Run outlook-email-pp-cli doctor to verify setup.
Agent Mode
Add --agent to any command. Expands to: --json --compact --no-input --no-color --yes.
Pipeable โ JSON on stdout, errors on stderr
Filterable โ --select keeps a subset of fields. Dotted paths descend into nested structures; arrays traverse element-wise. Critical for keeping context small on verbose APIs:
outlook-email-pp-cli attachments list mock-value --agent --selectid,name,status
Previewable โ --dry-run shows the request without sending
Offline-friendly โ sync/search commands can use the local SQLite store when available
Non-interactive โ never prompts, every input is a flag
Explicit retries โ use --idempotent only when an already-existing create should count as success, and --ignore-missing only when a missing delete target should count as success
Response envelope
Commands that read from the local store or the API wrap output in a provenance envelope:
Parse .results for data and .meta.source to know whether it's live or local. A human-readable N results (live) summary is printed to stderr only when stdout is a terminal โ piped/agent consumers get pure JSON on stdout.
Agent Feedback
When you (or the agent) notice something off about this CLI, record it:
outlook-email-pp-cli feedback "the --since flag is inclusive but docs say exclusive"
outlook-email-pp-cli feedback --stdin < notes.txt
outlook-email-pp-cli feedback list --json --limit 10
Entries are stored locally at ~/.outlook-email-pp-cli/feedback.jsonl. They are never POSTed unless OUTLOOK_EMAIL_FEEDBACK_ENDPOINT is set AND either --send is passed or OUTLOOK_EMAIL_FEEDBACK_AUTO_SEND=true. Default behavior is local-only.
Write what surprised you, not a bug report. Short, specific, one line: that is the part that compounds.
Output Delivery
Every command accepts --deliver <sink>. The output goes to the named sink in addition to (or instead of) stdout, so agents can route command results without hand-piping. Three sinks are supported:
Sink
Effect
stdout
Default; write to stdout only
file:<path>
Atomically write output to <path> (tmp + rename)
webhook:<url>
POST the output body to the URL (application/json or application/x-ndjson when --compact)
Unknown schemes are refused with a structured error naming the supported set. Webhook failures return non-zero and log the URL + HTTP status on stderr.
Named Profiles
A profile is a saved set of flag values, reused across invocations. Use it when a scheduled agent calls the same command every run with the same configuration - HeyGen's "Beacon" pattern.
outlook-email-pp-cli profile save briefing --json
outlook-email-pp-cli --profile briefing attachments list mock-value
outlook-email-pp-cli profile list --json
outlook-email-pp-cli profile show briefing
outlook-email-pp-cli profile delete briefing --yes
Explicit flags always win over profile values; profile values win over defaults. agent-context lists all available profiles under available_profiles so introspecting agents discover them at runtime.
Exit Codes
Code
Meaning
0
Success
2
Usage error (wrong arguments)
3
Resource not found
4
Authentication required
5
API error (upstream issue)
7
Rate limited (wait and retry)
10
Config error
Argument Parsing
Parse $ARGUMENTS:
Empty, help, or --help โ show outlook-email-pp-cli --help output
Starts with install โ ends with mcp โ MCP installation; otherwise โ see Prerequisites above
Anything else โ Direct Use (execute as CLI command with --agent)
MCP Server Installation
Install the MCP binary from this CLI's published public-library entry or pre-built release, then register it:
claude mcp add outlook-email-pp-mcp -- outlook-email-pp-mcp
Verify: claude mcp list
Direct Use
Check if installed: which outlook-email-pp-cli
If not found, offer to install (see Prerequisites at the top of this skill).
Match the user query to the best command from the Unique Capabilities and Command Reference above.