omni-notify-mcp 1.3.3 → 1.3.4
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/dist/ui/server.js +5 -5
- package/package.json +1 -1
package/dist/ui/server.js
CHANGED
|
@@ -395,11 +395,11 @@ app.post("/api/test/ntfy", async (_req, res) => {
|
|
|
395
395
|
try {
|
|
396
396
|
const base = (ntfy.serverUrl ?? "https://ntfy.sh").replace(/\/$/, "");
|
|
397
397
|
const headers = {
|
|
398
|
-
"Content-Type": "text/plain", "Title": "Claude Notify
|
|
398
|
+
"Content-Type": "text/plain; charset=utf-8", "Title": encodeURIComponent("Claude Notify - test"), "Priority": "3", "Tags": "white_check_mark",
|
|
399
399
|
};
|
|
400
400
|
if (ntfy.token)
|
|
401
401
|
headers["Authorization"] = `Bearer ${ntfy.token}`;
|
|
402
|
-
const r = await fetch(`${base}/${encodeURIComponent(ntfy.topic)}`, { method: "POST", headers, body: "Test from Claude Notify
|
|
402
|
+
const r = await fetch(`${base}/${encodeURIComponent(ntfy.topic)}`, { method: "POST", headers, body: Buffer.from("Test from Claude Notify - ntfy is working!", "utf8") });
|
|
403
403
|
if (!r.ok)
|
|
404
404
|
throw new Error(`ntfy ${r.status}: ${await r.text()}`);
|
|
405
405
|
res.json({ ok: true, message: `ntfy notification sent to topic '${ntfy.topic}'` });
|
|
@@ -816,15 +816,15 @@ async function sendNotification(message, priority, client) {
|
|
|
816
816
|
const base = (ntfy.serverUrl ?? "https://ntfy.sh").replace(/\/$/, "");
|
|
817
817
|
const priorityMap = { low: 2, normal: 3, high: 5 };
|
|
818
818
|
const headers = {
|
|
819
|
-
"Content-Type": "text/plain",
|
|
820
|
-
"Title": "Claude Notify",
|
|
819
|
+
"Content-Type": "text/plain; charset=utf-8",
|
|
820
|
+
"Title": encodeURIComponent("Claude Notify"),
|
|
821
821
|
"Priority": String(priorityMap[priority] ?? 3),
|
|
822
822
|
"Tags": priority === "high" ? "rotating_light" : "bell",
|
|
823
823
|
};
|
|
824
824
|
if (ntfy.token)
|
|
825
825
|
headers["Authorization"] = `Bearer ${ntfy.token}`;
|
|
826
826
|
const r = await fetch(`${base}/${encodeURIComponent(ntfy.topic)}`, {
|
|
827
|
-
method: "POST", headers, body: message,
|
|
827
|
+
method: "POST", headers, body: Buffer.from(message, "utf8"),
|
|
828
828
|
});
|
|
829
829
|
if (!r.ok)
|
|
830
830
|
throw new Error(`ntfy ${r.status}: ${await r.text()}`);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "omni-notify-mcp",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.4",
|
|
4
4
|
"description": "An MCP server that lets AI agents (Claude, Cursor, etc.) reach you on any channel — desktop, Telegram, SMS, email — with two-way ask/reply, real-time inbox push, Do Not Disturb, idle gating, multi-session routing, and a one-page web UI for setup. Zero config code; configure once, agents call notify/ask.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"type": "module",
|