@mattral/notifier 1.0.0 → 1.1.0
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 +34 -0
- package/package.json +1 -1
package/README.md
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# @mattral/notifier
|
|
2
|
+
|
|
3
|
+
Webhook and Slack delivery for [mcp-reliable](https://www.npmjs.com/package/mcp-reliable)
|
|
4
|
+
alerts.
|
|
5
|
+
|
|
6
|
+
```bash
|
|
7
|
+
npm install @mattral/notifier
|
|
8
|
+
```
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
```ts
|
|
13
|
+
import { createNotifier } from "@mattral/notifier";
|
|
14
|
+
|
|
15
|
+
const notifier = createNotifier({
|
|
16
|
+
webhookUrl: "https://example.com/hooks/mcp-reliable",
|
|
17
|
+
slackWebhookUrl: "https://hooks.slack.com/services/..."
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
// null if neither URL was provided; otherwise a single Notifier that
|
|
21
|
+
// delivers to whichever URL(s) were configured (both, if both are set —
|
|
22
|
+
// one failing to deliver doesn't block the other).
|
|
23
|
+
await notifier?.notify(alert);
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
## Learn more
|
|
27
|
+
|
|
28
|
+
See the [mcp-reliable GitHub repo](https://github.com/Mattral/mcp-reliable)
|
|
29
|
+
for how this fits into `mcp-reliable monitor` and `mcp-reliable proxy`'s
|
|
30
|
+
alerting.
|
|
31
|
+
|
|
32
|
+
## License
|
|
33
|
+
|
|
34
|
+
MIT
|