Skip to content
Back to skills

Email Integration

ASecurity

Integrates with any IMAP/SMTP mail server (Gmail, Outlook, Naver, Kakao, custom servers, etc.). Use when the user wants to read, send, search, reply to, or manage emails. Primary path: validate_config + email_client.py (hidden password setup via setup_account.py). If Python/config/IMAP auth fails, fall back to browser saved-login webmail (Gmail/Outlook) via browser-session-assist and use_profile=true after explicit user confirmation. Triggers: "메일 보여줘", "이메일 확인", "send email", "받은 편지함", "메일 보...

  • 30 stars
  • 0 votes
  • 0 copies
  • 6 views
  • Added November 8, 2026
ai-agentspythongoshellbashsecurity

Works with

  • cli

Security analysis

A100/100

Scanned November 8, 2026

npx -y skills add majiayu000/claude-skill-registry-data --skill email-integration --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Email Integration?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Email Integration
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/majiayu000-email-integration-claude-skill-registry-data/badge)](https://www.skillsdirectory.com/skills/majiayu000-email-integration-claude-skill-registry-data)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: email-integration
description: |
  Integrates with any IMAP/SMTP mail server (Gmail, Outlook, Naver, Kakao, custom servers, etc.).
  Use when the user wants to read, send, search, reply to, or manage emails.
  Primary path: validate_config + email_client.py (hidden password setup via setup_account.py).
  If Python/config/IMAP auth fails, fall back to browser saved-login webmail (Gmail/Outlook) via
  browser-session-assist and use_profile=true after explicit user confirmation.
  Triggers: "메일 보여줘", "이메일 확인", "send email", "받은 편지함", "메일 보내줘", "메일 검색".
---

# Email Integration

Interact with mail on behalf of the user. Prefer **IMAP/SMTP scripts** when they work; use **browser profile webmail** only as fallback.

## Path conventions

Paths are relative to this skill's Base Directory. Replace `<skill-base-dir>` with its absolute path in commands.

- On Linux/macOS, use `python3` if `python` is unavailable.
- Always quote paths: `"<skill-base-dir>/scripts/..."`.

## Security (mandatory)

- **NEVER** ask for passwords in chat or display `~/.libragent/email_config`
- Collect password only via a single hidden shell prompt; persist with `setup_account.py`
- If the user pastes a secret in chat, do not echo it—run setup immediately
- Browser fallback: **never** set `use_profile=true` without explicit user confirmation (see `browser-session-assist`)

## Decision tree

1. **Try IMAP script path** (steps 1–4 below).
2. **On failure** that blocks scripts, offer browser fallback (do not loop forever on setup):
   - `python` / `python3` missing
   - config missing/corrupt and user declines password setup, or setup/auth fails
   - IMAP/SMTP auth failure, app-password / Modern Auth blocked
3. If user agrees → follow [references/browser-fallback.md](references/browser-fallback.md) (uses `browser-session-assist`).
4. If `createSession` reports no imported profile → guide Settings import; if Google block → Open to sign in; then retry browser path.
5. If user declines all paths → explain IMAP setup vs Saved browser logins and stop.

## Workflow (IMAP primary)

### 1. Detect config

```bash
python "<skill-base-dir>/scripts/validate_config.py"
```

- Exit `0` → configured, go to step 3
- Exit `1` → not configured, go to step 2 (or offer browser fallback if user prefers)
- Exit `2` → corrupt config, go to step 2 with `--reset`

### 2. Setup (first time or reset)

See [references/setup-flow.md](references/setup-flow.md) for the PowerShell two-step pattern and preset/custom domain commands.

### 3. Dispatch action

Classify the request and call `email_client.py`:

| Action | When | Command |
|---|---|---|
| `read_inbox` | Browse inbox | `--action read_inbox [--limit N] [--filter unread\|today\|all]` |
| `read_email` | Full content by UID | `--action read_email --uid <UID>` |
| `send_email` | Compose/send/reply | `--action send_email --to ... --subject ... --body ... [--reply-to-uid <UID>]` |
| `search_email` | Keyword/sender/date | `--action search_email --query "<IMAP search>"` |
| `manage_email` | Mark/move/delete | `--action manage_email --uid <UID> --op <mark_read\|mark_unread\|move\|delete>` |

Search query examples: see [references/request-patterns.md](references/request-patterns.md).
Server presets: see [references/server-profiles.md](references/server-profiles.md).

Draft vague compose requests yourself; confirm with the user before sending.
For bulk delete/move, confirm count first.

### 4. Present results

See [references/output-format.md](references/output-format.md). Errors: [references/error-handling.md](references/error-handling.md).

## Browser fallback

See [references/browser-fallback.md](references/browser-fallback.md) and skill `browser-session-assist`.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.