mcp苹果日历
MCP服务器,用于通过AppleScript在macOS上与Apple日历进行交互。
需求
- macOS(使用AppleScript与Calendar.app通信)
- Node.js>=18
安装
使用npx(推荐)
无需安装。直接在MCP客户端中配置:
{
"mcpServers": {
"mcp-apple-calendar": {
"command": "npx",
"args": ["-y", "mcp-apple-calendar"]
}
}
}来源
git clone https://github.com/IPalSeb/mcp-apple-calendar.git
cd mcp-apple-calendar
npm install
npm run build然后配置:
{
"mcpServers": {
"mcp-apple-calendar": {
"command": "node",
"args": ["/path/to/mcp-apple-calendar/dist/index.js"]
}
}
}工具
list_calendars
列出所有可用日历。
参数:无
list_events
列出日期范围内的事件。
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
start | string | yes | ISO格式的开始日期(例如。 2026-01-30) |
end | string | yes | ISO格式的结束日期(例如。 2026-02-06) |
calendar | string | 否 | 按日历名称筛选 |
search_events
按标题文本搜索事件。
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
query | string | yes | 要在事件标题中搜索的文本 |
calendar | string | 否 | 按日历名称筛选 |
limit | number | no | 最大结果数(默认值20) |
create_event
创建新事件。
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
title | string | 是 | 事件标题 |
start | string | yes | 以ISO格式开始日期时间 |
end | string | yes | 结束ISO格式的日期时间 |
calendar | string | yes | 日历名称 |
location | string | 否 | 事件位置 |
description | string | 否 | 事件描述 |
allDay | boolean | no | 全天事件(默认为false) |
delete_event
按确切标题删除事件。
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
title | string | yes | 确切的事件标题 |
calendar | string | yes | 日历名称 |
权限
首次使用时,macOS会要求您授予运行服务器的终端应用程序(终端、iTerm2等)的日历访问权限。你必须允许这些工具工作。
许可证
麻省理工学院
