
Product
Introducing Repository Access Permissions and Custom Roles
Socket now supports Custom Roles and Repository Access Permissions so organizations can control who can access specific repositories and actions.
n8n-nodes-icloud
Advanced tools
An n8n community node for integrating Apple iCloud into your workflows — Mail, Calendar, and Contacts, with full AI Agent tool support.
| Resource | Operations | Protocol |
|---|---|---|
| Send (incl. attachments), Get Emails, Get by ID, Move, Delete | SMTP / IMAP | |
| Calendar | List Calendars, Get Events, Create, Update, Delete | CalDAV |
| Contacts | Get Contacts, Create, Update, Delete | CardDAV |
usableAsTool: true — Works as an AI Agent tool in n8np01-caldav.icloud.com, p02-..., etc.)xxxx-xxxx-xxxx-xxxx)n8n-nodes-icloudnpm install n8n-nodes-icloud
Or via Docker:
docker exec <container> npm install --prefix /home/node/.n8n/nodes n8n-nodes-icloud
docker restart <container>
Set this environment variable on your n8n instance:
N8N_COMMUNITY_PACKAGES_ALLOW_TOOL_USAGE=true
In n8n, add new credentials of type "Apple iCloud Credentials":
| Field | Required | Description |
|---|---|---|
| Apple ID | Yes | Your Apple ID email (e.g., yourname@icloud.com or a Gmail/custom domain) |
| App-Specific Password | Yes | The generated app-specific password (xxxx-xxxx-xxxx-xxxx) |
| iCloud Mail Address | No | Your @icloud.com / @me.com / @mac.com address — only needed for Mail (IMAP/SMTP) if your Apple ID is not already an iCloud address |
Why is the Mail Address field needed? iCloud's IMAP and SMTP servers (
imap.mail.me.com,smtp.mail.me.com) only accept@icloud.com,@me.com, or@mac.comas the username. If your Apple ID is a Gmail or custom domain address, IMAP/SMTP authentication will fail with "Command failed" — even though Calendar and Contacts work fine (they use any Apple ID via CalDAV/CardDAV). Solution: Enter your iCloud mail address in the optional field. Calendar and Contacts are unaffected.
Sends an email via iCloud Mail SMTP (smtp.mail.me.com:587, STARTTLS).
| Parameter | Type | Required | Description |
|---|---|---|---|
| To | string | Yes | Recipient email(s), comma-separated |
| Subject | string | Yes | Email subject |
| Body | string | Yes | Email body |
| CC | string | No | Carbon copy recipient(s) |
| BCC | string | No | Blind carbon copy |
| Send as HTML | boolean | No | Treat body as HTML |
| Attachments | fixedCollection | No | One or more binary files to attach (see below) |
Attaching files: Connect an upstream node that outputs binary data (e.g. Read/Write Files from Disk, HTTP Request, Google Drive). In the Attachments section, set Binary Property to the name of the binary field (default: data). Multiple attachments are supported.
[Read File] ──→ [iCloud: Send Email]
Attachments:
Binary Property: data ← matches output of Read File node
File Name: (optional override)
Retrieves emails from an IMAP mailbox (imap.mail.me.com:993, SSL).
| Parameter | Type | Default | Description |
|---|---|---|---|
| Mailbox | string | INBOX | Folder name. Common iCloud mailboxes: INBOX, Sent Messages, Drafts, Deleted Messages, Junk |
| Limit | number | 10 | Max emails to return (newest first) |
| From | string | — | Filter by sender |
| Subject Contains | string | — | Filter by subject |
| Only Unread | boolean | false | Return only unread emails |
| Since | dateTime | — | Return emails after this date |
Retrieves a single email by its IMAP UID (includes full body).
Moves an email from one mailbox to another.
Permanently deletes an email by UID.
Returns all calendars with their URLs, display names, and colors.
Retrieves events from one or all calendars, optionally filtered by date range.
| Parameter | Type | Description |
|---|---|---|
| Calendar URL | string | Optional — leave empty for all calendars |
| Start | dateTime | Optional filter: events after this date |
| End | dateTime | Optional filter: events before this date |
| Parameter | Type | Required | Description |
|---|---|---|---|
| Calendar | options | Yes | Target calendar (dropdown from Get Calendars) |
| Summary | string | Yes | Event title |
| Start | dateTime | Yes | Start date/time |
| End | dateTime | Yes | End date/time (must be after Start) |
| Description | string | No | Event notes |
| Location | string | No | Event location |
| All Day Event | boolean | No | Full-day event flag |
| Timezone | string | No | IANA timezone (e.g. Europe/Berlin). Leave empty for UTC. |
Returns: { success, uid, url, etag, summary, start, end }
Updates fields on an existing event. Requires Calendar (dropdown) + Event UID (returned as uid by Get Events or Create Event).
Deletes an event. Requires Calendar (dropdown) + Event UID.
Returns all contacts, with optional search filtering by name or email.
| Parameter | Type | Required | Description |
|---|---|---|---|
| First Name | string | Yes | Contact's first name |
| Last Name | string | No | Contact's last name |
| string | No | Email address | |
| Phone | string | No | Phone number |
| Notes | string | No | Additional notes |
Updates fields on an existing contact. Requires Contact UID (returned as uid by Get Contacts or Create Contact).
Deletes a contact. Requires Contact UID.
The iCloud Trigger node polls your IMAP mailbox at a configurable interval and fires whenever new emails arrive.
| Parameter | Type | Default | Description |
|---|---|---|---|
| Mailbox | string | INBOX | Folder to watch (e.g. INBOX, Sent Messages, Junk) |
| Initial Lookback (Hours) | number | 0 | On first activation, return emails from the last N hours. 0 = silent start (no old emails). |
| From | string | — | Only trigger for emails from this sender |
| To Address Contains | string | — | Only trigger for emails addressed to this recipient |
| Subject Contains | string | — | Only trigger when subject contains this text |
| Only Unread | boolean | false | Only trigger for emails not yet read in any mail client |
| Has Attachments | boolean | false | Only trigger for emails with at least one attachment |
How it works:
Output fields: uid, messageId, from, to, cc, subject, date, flags, size
Tip: Use Get Email by ID after the trigger to fetch the full email body (the trigger returns envelope data only for efficiency).
This node has usableAsTool: true, so it works directly as a tool in n8n AI Agent workflows.
Example prompts:
Setup:
If you were using the old n8n-nodes-apple-icloud package (Calendar-only):
n8n-nodes-icloud (this package)| Protocol | Host | Port | Security |
|---|---|---|---|
| SMTP | smtp.mail.me.com | 587 | STARTTLS |
| IMAP | imap.mail.me.com | 993 | SSL/TLS |
| CalDAV | caldav.icloud.com | 443 | HTTPS (auto-discovery) |
| CardDAV | contacts.icloud.com | 443 | HTTPS (auto-discovery) |
Note: CalDAV and CardDAV use account-specific server endpoints (
p01-caldav.icloud.com,p02-...). Thetsdavlibrary handles server discovery automatically via PROPFIND.
Authentication errors (Invalid credentials / 535):
IMAP connection errors:
CalDAV/CardDAV errors (403 Forbidden):
Node not appearing in n8n:
N8N_COMMUNITY_PACKAGES_ALLOW_TOOL_USAGE=true is set if using as AI tool| Package | Version | Purpose |
|---|---|---|
nodemailer | ^6.9.0 | SMTP email sending |
imapflow | ^1.0.170 | IMAP email retrieval |
tsdav | ^2.1.6 | CalDAV / CardDAV (Calendar + Contacts) |
MIT — see LICENSE
OzDreamWalk — ozdreamwalk.com
FAQs
n8n community node for Apple iCloud — Mail, Calendar, and Contacts
The npm package n8n-nodes-icloud receives a total of 96 weekly downloads. As such, n8n-nodes-icloud popularity was classified as not popular.
We found that n8n-nodes-icloud demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Socket now supports Custom Roles and Repository Access Permissions so organizations can control who can access specific repositories and actions.

Product
Socket MCP now lets AI assistants review org alerts, investigate threats using the Socket threat feed, and inspect package files in addition to dependency scoring.

Product
Socket Firewall blocks malicious VS Code and Open VSX extensions before install, protecting developers from compromised editor marketplaces.