himalaya

Manage IMAP and SMTP email accounts from the terminal using the Himalaya CLI.

Updated Jul 3, 2026
One-click install
npx skills add https://github.com/CHENHUI-X/toolbox --skill himalaya-chenhui-x
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: himalaya
Source: https://github.com/CHENHUI-X/toolbox/tree/main/official-skills/email/himalaya
Command: npx skills add https://github.com/CHENHUI-X/toolbox --skill himalaya-chenhui-x

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Reading, searching, composing, and organizing email typically requires a GUI client or web interface, which blocks automation. This Skill lets an agent operate a full mailbox from the terminal using the Himalaya CLI over IMAP and SMTP. ## Core Features & Use Cases - Mailbox Operations: List folders and envelopes, search messages, read or export raw MIME, move, copy, delete, and manage flags across multiple accounts. - Non-Interactive Composition: Send, reply, and forward by piping MML templates via stdin, with support for HTML parts, attachments, and inline images. - Provider Configuration: Reference guides cover IMAP/SMTP setup for Gmail, iCloud, OAuth2, Notmuch, and the v1.2.0 folder-alias syntax that prevents duplicate-send failures on Gmail. - Use Case: Ask the agent to check your inbox for unread messages from a client, draft a reply with an attached report, and archive the thread — all without opening a mail app. ## Quick Start Ask the agent to list the ten most recent emails in your inbox using himalaya envelope list after installing the CLI and configuring an account.

Frequently Asked Questions about himalaya

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I send an email from the command line with himalaya?

Pipe a message with headers and body into himalaya template send using a heredoc, or use himalaya message write with -H header flags. Piping is recommended for non-interactive use since plain message write opens $EDITOR.

How do I configure himalaya for Gmail IMAP and SMTP?

Create a config.toml account pointing to imap.gmail.com:993 and smtp.gmail.com:587 with an app password. You must also set folder.aliases mapping sent to [Gmail]/Sent Mail, or saving sent copies fails after delivery.

Why does himalaya message send fail after the email was delivered?

This happens when folder aliases use the old singular [accounts.NAME.folder.alias] syntax, which v1.2.0 silently ignores. The save-to-Sent step then fails after SMTP succeeds, and retrying sends duplicates. Use the plural folder.aliases.X keys.

Can himalaya handle email attachments and HTML messages?

Yes. Attachments are added with MML part tags specifying a filename, and multipart/alternative or related structures support HTML bodies and inline images. Received attachments are saved with himalaya attachment download.

Does himalaya support multiple email accounts?

Yes. Define multiple [accounts.NAME] sections in config.toml and mark one as default. Switch accounts per command with the --account flag, and list configured accounts with himalaya account list.