@highcaliberai/notify
v0.1.1
Published
Tiny client for the High Caliber AI notifications hub (Extra Lovable). Connect any app in 3 lines — mute, throttle, kill-switch all controlled remotely from the hub.
Downloads
91
Maintainers
Readme
@highcaliberai/notify
Tiny client for the Extra Lovable notifications hub — the operations hub for the High Caliber AI network of apps.
Connect any app in 3 lines. After install, everything (mute event types, throttle,
kill switch, sampling, severity overrides) is controlled remotely from the hub via
project_config. You shouldn't need to ship code changes to your app to change alert
behavior — just run bun update @highcaliberai/notify once in a while to pick up
wire-format changes.
Install
bun add @highcaliberai/notify
# or: npm install @highcaliberai/notifySet a project secret:
NOTIFY_KEY=lvn_xxx # generated at https://extralovable.com/snippetUse
import { notify } from "@highcaliberai/notify";
await notify({
type: "signup",
title: `${email} joined`,
metadata: { email, plan },
});That's it. Auto-instrumentation for window.error, unhandledrejection, and 5xx
fetch responses is enabled by default in the browser.
Custom hub URL
If you self-host the hub or use a different deployment:
import { initNotify } from "@highcaliberai/notify";
initNotify({ hubUrl: "https://my-hub.example.com" });Severity & metadata
await notify({
type: "purchase",
severity: "info", // "info" | "warn" | "error" | "critical"
title: "New purchase",
metadata: { amount: 99, currency: "USD" },
dedupeKey: `purchase:${orderId}`,
ai_cost_usd: 0.0042,
});ESM-only fallback (no install)
If you can't add an npm dep, you can pull the same client directly from the hub:
<script type="module">
import { notify } from "https://extralovable.com/api/public/notify.js";
await notify({ type: "test", title: "hello from CDN" });
</script>License
MIT
