Quick Start
Invoke tools via CLI:
# Install dependencies first
cd .opencode/skills/fastmail && bun install
# Email: List mailboxes
bunx fastmail list_mailboxes
# Email: Send
bunx fastmail send_email \
'{"to": [{"email": "user@example.com"}], "subject": "Hi", "text_body": "Message"}'
# Calendar: List events
bunx fastmail list_events \
'{"start_date": "2024-01-01", "end_date": "2024-01-31"}'
# Calendar: Create event with reminder
bunx fastmail create_event_with_reminder \
'{"title": "Meeting", "start": "2024-01-15T10:00:00", "end": "2024-01-15T11:00:00", "reminder_minutes": [15, 60]}'
# List all available tools
bunx fastmail --list
When to Use This Skill
- 📧 Check inbox or search emails
- 📧 Send, reply, or move emails
- 🏷️ Apply labels or organize mailbox
- 📅 View calendar or events
- 📅 Create, update, or delete events
- 🔔 Set event reminders or alarms
Email Tools (10 total)
| Tool |
Purpose |
list_mailboxes |
List all folders |
list_emails |
List emails in mailbox |
get_email |
Get full email content |
get_thread |
Get all emails in a conversation thread |
search_emails |
Search by text query |
send_email |
Send new email |
reply_email |
Reply to email |
move_email |
Move to folder |
set_labels |
Apply labels ($seen, $flagged) |
delete_email |
Delete (move to trash) |
Bulk Email Tools (3 total)
| Tool |
Purpose |
bulk_move_emails |
Move multiple emails at once |
bulk_set_labels |
Apply labels to multiple emails |
bulk_delete_emails |
Delete multiple emails at once |
Calendar Tools (10 total)
| Tool |
Purpose |
list_calendars |
List all calendars |
list_events |
List events by date range |
get_event |
Get event details |
create_event |
Create new event |
update_event |
Update existing event |
delete_event |
Delete event |
search_events |
Search by title/description |
create_recurring_event |
Create repeating event |
list_invitations |
List calendar invitations |
respond_to_invitation |
Accept/decline/maybe invitations |
Reminder Tools (4 total)
| Tool |
Purpose |
add_event_reminder |
Add reminder to event |
remove_event_reminder |
Remove reminder(s) |
list_event_reminders |
List reminders for event |
create_event_with_reminder |
Create event + reminder in one call |
Common Examples
# Check inbox (limit 10)
bunx fastmail list_emails '{"limit": 10}'
# Search for emails
bunx fastmail search_emails '{"query": "invoice"}'
# Get specific email content
bunx fastmail get_email '{"email_id": "xxx"}'
# Get email thread/conversation
bunx fastmail get_thread '{"email_id": "xxx"}'
# Bulk operations
bunx fastmail bulk_move_emails '{"email_ids": ["id1", "id2"], "target_mailbox_id": "archive"}'
bunx fastmail bulk_delete_emails '{"email_ids": ["id1", "id2", "id3"]}'
# Create recurring event (daily for 10 days)
bunx fastmail create_recurring_event \
'{"title": "Standup", "start": "2024-01-01T09:00:00", "end": "2024-01-01T09:30:00", "recurrence": "daily", "recurrence_count": 10}'
# Calendar invitations
bunx fastmail list_invitations
bunx fastmail respond_to_invitation '{"event_id": "xxx", "response": "accept"}'
Decision Tree
Need to manage email?
- List/search →
list_emails or search_emails
- Read content →
get_email
- View conversation →
get_thread
- Send/reply →
send_email or reply_email
- Organize →
move_email, set_labels, delete_email
- Bulk actions →
bulk_move_emails, bulk_set_labels, bulk_delete_emails
Need to manage calendar?
- View →
list_calendars or list_events
- Create →
create_event or create_recurring_event
- Modify →
update_event
- Delete →
delete_event
- Invitations →
list_invitations, respond_to_invitation
Need reminders?
- Add to existing event →
add_event_reminder
- Create event + reminder →
create_event_with_reminder (faster)
- Manage →
list_event_reminders, remove_event_reminder
Output Format
All tools return JSON:
{
"success": true,
"data": { /* tool-specific response */ },
"timestamp": "2024-01-15T10:00:00+07:00"
}
Environment Variables
| Variable |
Purpose |
Required |
FASTMAIL_API_TOKEN |
Email via JMAP |
Yes (for email) |
FASTMAIL_USERNAME |
Calendar via CalDAV |
Yes (for calendar) |
FASTMAIL_PASSWORD |
Calendar app password |
Yes (for calendar) |
FASTMAIL_TIMEZONE |
Calendar timezone (IANA format) |
No (auto-detected) |
Setup:
export FASTMAIL_API_TOKEN="your-api-token"
export FASTMAIL_USERNAME="your-email@fastmail.com"
export FASTMAIL_PASSWORD="your-app-password"
# Optional: Override timezone (defaults to system local timezone)
export FASTMAIL_TIMEZONE="America/New_York" # or "Asia/Bangkok", "Europe/London", etc.
Timezone Support
⏰ Configurable calendar timezone
- Default: Auto-detects your system's local timezone
- Override: Set
FASTMAIL_TIMEZONE environment variable
- Uses IANA timezone identifiers (e.g.,
America/New_York, Asia/Bangkok, Europe/London)
- Input times assumed in configured timezone
- Output times shown in configured timezone
- Stored internally as UTC
- Handles Daylight Saving Time (DST) automatically
See Also
- Detailed reference:
.opencode/skills/fastmail/references/TOOLS.md
- Full guide:
.opencode/skills/fastmail/README.md
- Setup help: Fastmail Settings → Privacy & Security → Integrations
1---2name: fastmail3description: Manages Fastmail email and calendar via JMAP and CalDAV APIs. Use for emails (read, send, reply, search, organize, bulk operations, threads) or calendar (events, reminders, RSVP invitations). Timezone auto-detected from system.4---5
6## Quick Start
7
8Invoke tools via CLI:
9
10```bash
11# Install dependencies first
12cd .opencode/skills/fastmail && bun install
13
14# Email: List mailboxes
15bunx fastmail list_mailboxes
16
17# Email: Send
18bunx fastmail send_email \
19 '{"to": [{"email": "user@example.com"}], "subject": "Hi", "text_body": "Message"}'
20
21# Calendar: List events
22bunx fastmail list_events \
23 '{"start_date": "2024-01-01", "end_date": "2024-01-31"}'
24
25# Calendar: Create event with reminder
26bunx fastmail create_event_with_reminder \
27 '{"title": "Meeting", "start": "2024-01-15T10:00:00", "end": "2024-01-15T11:00:00", "reminder_minutes": [15, 60]}'
28
29# List all available tools
30bunx fastmail --list
31```
32
33## When to Use This Skill
34
35- 📧 Check inbox or search emails
36- 📧 Send, reply, or move emails
37- 🏷️ Apply labels or organize mailbox
38- 📅 View calendar or events
39- 📅 Create, update, or delete events
40- 🔔 Set event reminders or alarms
41
42## Email Tools (10 total)
43
44| Tool | Purpose |
45|------|---------|
46| `list_mailboxes` | List all folders |
47| `list_emails` | List emails in mailbox |
48| `get_email` | Get full email content |
49| `get_thread` | Get all emails in a conversation thread |
50| `search_emails` | Search by text query |
51| `send_email` | Send new email |
52| `reply_email` | Reply to email |
53| `move_email` | Move to folder |
54| `set_labels` | Apply labels ($seen, $flagged) |
55| `delete_email` | Delete (move to trash) |
56
57## Bulk Email Tools (3 total)
58
59| Tool | Purpose |
60|------|---------|
61| `bulk_move_emails` | Move multiple emails at once |
62| `bulk_set_labels` | Apply labels to multiple emails |
63| `bulk_delete_emails` | Delete multiple emails at once |
64
65## Calendar Tools (10 total)
66
67| Tool | Purpose |
68|------|---------|
69| `list_calendars` | List all calendars |
70| `list_events` | List events by date range |
71| `get_event` | Get event details |
72| `create_event` | Create new event |
73| `update_event` | Update existing event |
74| `delete_event` | Delete event |
75| `search_events` | Search by title/description |
76| `create_recurring_event` | Create repeating event |
77| `list_invitations` | List calendar invitations |
78| `respond_to_invitation` | Accept/decline/maybe invitations |
79
80## Reminder Tools (4 total)
81
82| Tool | Purpose |
83|------|---------|
84| `add_event_reminder` | Add reminder to event |
85| `remove_event_reminder` | Remove reminder(s) |
86| `list_event_reminders` | List reminders for event |
87| `create_event_with_reminder` | Create event + reminder in one call |
88
89## Common Examples
90
91```bash
92# Check inbox (limit 10)
93bunx fastmail list_emails '{"limit": 10}'
94
95# Search for emails
96bunx fastmail search_emails '{"query": "invoice"}'
97
98# Get specific email content
99bunx fastmail get_email '{"email_id": "xxx"}'
100
101# Get email thread/conversation
102bunx fastmail get_thread '{"email_id": "xxx"}'
103
104# Bulk operations
105bunx fastmail bulk_move_emails '{"email_ids": ["id1", "id2"], "target_mailbox_id": "archive"}'
106bunx fastmail bulk_delete_emails '{"email_ids": ["id1", "id2", "id3"]}'
107
108# Create recurring event (daily for 10 days)
109bunx fastmail create_recurring_event \
110 '{"title": "Standup", "start": "2024-01-01T09:00:00", "end": "2024-01-01T09:30:00", "recurrence": "daily", "recurrence_count": 10}'
111
112# Calendar invitations
113bunx fastmail list_invitations
114bunx fastmail respond_to_invitation '{"event_id": "xxx", "response": "accept"}'
115```
116
117## Decision Tree
118
119**Need to manage email?**
120- List/search → `list_emails` or `search_emails`
121- Read content → `get_email`
122- View conversation → `get_thread`
123- Send/reply → `send_email` or `reply_email`
124- Organize → `move_email`, `set_labels`, `delete_email`
125- Bulk actions → `bulk_move_emails`, `bulk_set_labels`, `bulk_delete_emails`
126
127**Need to manage calendar?**
128- View → `list_calendars` or `list_events`
129- Create → `create_event` or `create_recurring_event`
130- Modify → `update_event`
131- Delete → `delete_event`
132- Invitations → `list_invitations`, `respond_to_invitation`
133
134**Need reminders?**
135- Add to existing event → `add_event_reminder`
136- Create event + reminder → `create_event_with_reminder` (faster)
137- Manage → `list_event_reminders`, `remove_event_reminder`
138
139## Output Format
140
141All tools return JSON:
142
143```json
144{
145 "success": true,
146 "data": { /* tool-specific response */ },
147 "timestamp": "2024-01-15T10:00:00+07:00"
148}
149```
150
151## Environment Variables
152
153| Variable | Purpose | Required |
154|----------|---------|----------|
155| `FASTMAIL_API_TOKEN` | Email via JMAP | Yes (for email) |
156| `FASTMAIL_USERNAME` | Calendar via CalDAV | Yes (for calendar) |
157| `FASTMAIL_PASSWORD` | Calendar app password | Yes (for calendar) |
158| `FASTMAIL_TIMEZONE` | Calendar timezone (IANA format) | No (auto-detected) |
159
160**Setup:**
161```bash
162export FASTMAIL_API_TOKEN="your-api-token"
163export FASTMAIL_USERNAME="your-email@fastmail.com"
164export FASTMAIL_PASSWORD="your-app-password"
165# Optional: Override timezone (defaults to system local timezone)
166export FASTMAIL_TIMEZONE="America/New_York" # or "Asia/Bangkok", "Europe/London", etc.
167```
168
169## Timezone Support
170
171⏰ **Configurable calendar timezone**
172- **Default:** Auto-detects your system's local timezone
173- **Override:** Set `FASTMAIL_TIMEZONE` environment variable
174- Uses IANA timezone identifiers (e.g., `America/New_York`, `Asia/Bangkok`, `Europe/London`)
175- Input times assumed in configured timezone
176- Output times shown in configured timezone
177- Stored internally as UTC
178- Handles Daylight Saving Time (DST) automatically
179
180## See Also
181
182- **Detailed reference:** `.opencode/skills/fastmail/references/TOOLS.md`
183- **Full guide:** `.opencode/skills/fastmail/README.md`
184- **Setup help:** Fastmail Settings → Privacy & Security → Integrations