himalaya

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

Updated May 29, 2026
One-click install
npx skills add https://github.com/m4an5you6/aspera-agent --skill himalaya-m4an5you6
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: himalaya
Source: https://github.com/m4an5you6/aspera-agent/tree/main/skills/email/himalaya
Command: npx skills add https://github.com/m4an5you6/aspera-agent --skill himalaya-m4an5you6

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Reading, searching, and sending email typically requires a GUI client or custom API integrations. This Skill lets an agent operate a full mailbox directly from the terminal using the Himalaya CLI, covering IMAP/SMTP accounts without building email protocol code. ## Core Features & Use Cases - Mailbox Operations: List folders and envelopes, search messages, read emails, download attachments, and move, copy, delete, or flag messages. - Non-Interactive Sending: Compose, reply, and forward emails by piping MML/MIME templates via stdin, including HTML bodies, inline images, and file attachments. - Multi-Account Configuration: Set up IMAP/SMTP, Notmuch, or OAuth2 backends for providers like Gmail and iCloud with secure password handling via pass or keyring. - Use Case: Ask the agent to check your inbox for unread messages from a client, summarize them, and send a reply with a PDF attachment — all executed through terminal commands. ## Quick Start Install the himalaya CLI, configure an account in ~/.config/himalaya/config.toml, then ask the agent to list your latest inbox messages and reply to one of them.

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, for example cat << 'EOF' | himalaya template send with From, To, and Subject headers. This non-interactive method avoids opening an editor and works reliably from scripts or agents.

How to configure himalaya for Gmail IMAP and SMTP?▼

Create an account in ~/.config/himalaya/config.toml pointing to imap.gmail.com:993 and smtp.gmail.com:587, using an app password if 2FA is enabled. You must also set folder.aliases mapping sent to [Gmail]/Sent Mail, drafts to [Gmail]/Drafts, and trash to [Gmail]/Trash.

Does himalaya support multiple email accounts?▼

Yes, define multiple [accounts.NAME] sections in the config file and mark one as default. Switch between them at runtime with the --account flag, for example himalaya --account work envelope list.

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

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

Can himalaya send emails with attachments?▼

Yes, compose the message using MML syntax with <#part filename=/path/to/file.pdf> tags inside the body, then pipe it to himalaya template send. MML compiles the parts into proper MIME, supporting multiple attachments, HTML bodies, and inline images.

How do I store email passwords securely for himalaya?▼

Use backend.auth.cmd to call a password command such as pass show email/imap, or backend.auth.keyring for the system keyring. Avoid backend.auth.raw, which stores the plaintext password in the config file and is only suitable for testing.