caldav-mcp 0.11.0 → 0.11.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -2
- package/dist/http-server.js +3 -1
- package/dist/index.js +35 -2
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
|
|
5
5
|
🗓️ A CalDAV Model Context Protocol (MCP) server to expose calendar operations as tools for AI assistants.
|
|
6
6
|
|
|
7
|
-
[](https://github.com/langmail/caldav-mcp/actions/workflows/release.yml)
|
|
8
8
|
[](https://www.npmjs.com/package/caldav-mcp)
|
|
9
9
|
[](https://choosealicense.com/licenses/mit/)
|
|
10
|
-
[](https://biomejs.dev)
|
|
11
11
|
[](https://modelcontextprotocol.io)
|
|
12
12
|
[](https://github.com/semantic-release/semantic-release)
|
|
13
13
|
|
|
@@ -25,6 +25,10 @@ Using caldav-mcp? [Tell us how in three minutes](https://tally.so/r/GepQM2?sourc
|
|
|
25
25
|
- Create calendar events
|
|
26
26
|
- Update calendar events
|
|
27
27
|
- Delete calendar events by UID
|
|
28
|
+
- List tasks (VTODOs), open ones by default or filtered by status
|
|
29
|
+
- Create and update tasks, with optional due and start dates
|
|
30
|
+
- Mark tasks as completed
|
|
31
|
+
- Delete tasks by UID
|
|
28
32
|
|
|
29
33
|
## Setup
|
|
30
34
|
|
package/dist/http-server.js
CHANGED
|
@@ -104,7 +104,9 @@ export function startHttpServer(config, createServer) {
|
|
|
104
104
|
send(res, 400, "Bad Request");
|
|
105
105
|
return;
|
|
106
106
|
}
|
|
107
|
-
|
|
107
|
+
// Node omits the body for HEAD, which some health probes send.
|
|
108
|
+
if (pathname === HEALTH_PATH &&
|
|
109
|
+
(req.method === "GET" || req.method === "HEAD")) {
|
|
108
110
|
send(res, 200, "ok");
|
|
109
111
|
return;
|
|
110
112
|
}
|
package/dist/index.js
CHANGED
|
@@ -11,7 +11,8 @@ function listeningUrl(server) {
|
|
|
11
11
|
function shutDownOnSignals(server) {
|
|
12
12
|
const shutdown = () => {
|
|
13
13
|
server.close(() => process.exit(0));
|
|
14
|
-
|
|
14
|
+
// closeIdleConnections only exists from Node 18.2; engines allows 18.0.
|
|
15
|
+
server.closeIdleConnections?.();
|
|
15
16
|
};
|
|
16
17
|
process.once("SIGINT", shutdown);
|
|
17
18
|
process.once("SIGTERM", shutdown);
|
|
@@ -56,4 +57,36 @@ async function main() {
|
|
|
56
57
|
// Start receiving messages on stdin and sending messages on stdout
|
|
57
58
|
await createServer(client).connect(new StdioServerTransport());
|
|
58
59
|
}
|
|
59
|
-
|
|
60
|
+
const MAX_CAUSE_DEPTH = 5;
|
|
61
|
+
/** undici's AggregateError for a refused multi-address connect has no message. */
|
|
62
|
+
function messageOf(error) {
|
|
63
|
+
if (error.message) {
|
|
64
|
+
return error.message;
|
|
65
|
+
}
|
|
66
|
+
const { code } = error;
|
|
67
|
+
return typeof code === "string" ? code : error.name;
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* One line for a startup error, with its cause chain: ts-caldav and fetch
|
|
71
|
+
* keep the actual network reason (ENOTFOUND, TLS errors) only in `cause`.
|
|
72
|
+
*/
|
|
73
|
+
function describeError(error) {
|
|
74
|
+
if (!(error instanceof Error)) {
|
|
75
|
+
return String(error);
|
|
76
|
+
}
|
|
77
|
+
const causes = [];
|
|
78
|
+
let { cause } = error;
|
|
79
|
+
while (cause instanceof Error && causes.length < MAX_CAUSE_DEPTH) {
|
|
80
|
+
causes.push(messageOf(cause));
|
|
81
|
+
({ cause } = cause);
|
|
82
|
+
}
|
|
83
|
+
return causes.length > 0
|
|
84
|
+
? `${error.message} (${causes.join(": ")})`
|
|
85
|
+
: error.message;
|
|
86
|
+
}
|
|
87
|
+
main().catch((error) => {
|
|
88
|
+
// e.g. EADDRINUSE or an unreachable CalDAV server: one readable line
|
|
89
|
+
// instead of an unhandled rejection.
|
|
90
|
+
console.error(`caldav-mcp: failed to start: ${describeError(error)}`);
|
|
91
|
+
process.exit(1);
|
|
92
|
+
});
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "caldav-mcp",
|
|
3
|
-
"version": "0.11.
|
|
3
|
+
"version": "0.11.2",
|
|
4
4
|
"description": "A CalDAV client using Model Context Protocol (MCP) to expose calendar operations as tools for AI assistants.",
|
|
5
|
-
"homepage": "https://github.com/
|
|
5
|
+
"homepage": "https://github.com/langmail/caldav-mcp#readme",
|
|
6
6
|
"bugs": {
|
|
7
|
-
"url": "https://github.com/
|
|
7
|
+
"url": "https://github.com/langmail/caldav-mcp/issues"
|
|
8
8
|
},
|
|
9
9
|
"repository": {
|
|
10
10
|
"type": "git",
|
|
11
|
-
"url": "https://github.com/
|
|
11
|
+
"url": "https://github.com/langmail/caldav-mcp.git"
|
|
12
12
|
},
|
|
13
13
|
"license": "MIT",
|
|
14
14
|
"author": "Dominik Grusemann",
|
|
@@ -69,5 +69,5 @@
|
|
|
69
69
|
"node": ">=18.0.0",
|
|
70
70
|
"npm": ">=9.0.0"
|
|
71
71
|
},
|
|
72
|
-
"mcpName": "io.github.
|
|
72
|
+
"mcpName": "io.github.langmail/caldav-mcp"
|
|
73
73
|
}
|