notifkit 0.1.6 → 0.1.7

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 CHANGED
@@ -85,7 +85,7 @@ flowchart TD
85
85
 
86
86
  In a single process, the API and all workers run in the same Node.js process (`services: ["all"]`), which works for small and medium apps, side projects, and staging. Distributed, you run stateless API servers (`services: ["api"]`) behind a load balancer and scale worker pools (`services: ["enricher", "engine", "delivery", "scheduler"]`) horizontally across Redis Streams consumer groups.
87
87
 
88
- ## Quickstart
88
+ ## Quickstart (needs 5 mins)
89
89
 
90
90
  ### 1. Install
91
91
 
@@ -123,6 +123,8 @@ await server.start();
123
123
  console.log("notifkit listening on http://localhost:3000");
124
124
  ```
125
125
 
126
+ `from` is required on `ResendTransport` — it is the sender for any template that does not name its own, and it has to be an address on a domain you have verified in Resend. A template can override it with its own `from`, so one transport can serve both `no-reply@` receipts and `marketing@` campaigns.
127
+
126
128
  `ADMIN_API_KEY` is the root credential. It is read from the environment, it is what mints project API keys in the next step, and without it the project-management routes answer `403`. Any string works locally:
127
129
 
128
130
  ```bash
@@ -173,8 +175,8 @@ await notifkit.syncTemplates({
173
175
  ],
174
176
  });
175
177
 
176
- // 2. Register a user
177
- await notifkit.addUser({ id: "usr_123", email: "alex@acme.com" });
178
+ // 2. Register a user (supports id + contacts array or object)
179
+ await notifkit.addUser("usr_123", [{ channel: "email", target: "alex@acme.com" }]);
178
180
 
179
181
  // 3. Dispatch
180
182
  await notifkit.notify({
@@ -263,20 +265,6 @@ notifkit is the durable notification layer that runs inside your own stack. It i
263
265
 
264
266
  First-party providers cover Resend, Firebase Cloud Messaging, Slack, Twilio, Telegram, Discord, and WhatsApp. Anything else is a `Transport` class with a `send()` method.
265
267
 
266
- ### How this compares to Novu
267
-
268
- Novu is the established open-source project in this space, and if you want a notification platform with a dashboard, a visual workflow editor, and a drop-in in-app inbox component, use Novu. It is more mature, has a much larger community, and solves a broader problem.
269
-
270
- notifkit is a narrower, more embeddable take on the same layer:
271
-
272
- - **A library first, a platform second.** notifkit is an npm package you can run inside your existing Node process. Novu self-hosts as a set of services (API, worker, WebSocket server, dashboard SPA) that you deploy and operate alongside your app.
273
- - **Postgres, not MongoDB.** notifkit stores state in PostgreSQL with Drizzle migrations and queues in Redis Streams. If Postgres is already your database, there is no new datastore to run.
274
- - **Workflows as code.** Multi-step sequences are typed TypeScript, versioned in your repo, rather than built in a visual editor.
275
- - **MIT, all of it.** There is no open-core split. Novu is MIT at the core with enterprise features under a commercial license; notifkit has no feature held back from the self-hosted build.
276
- - **MCP as a first-class interface.** Agents operate the same infrastructure your app uses, including triage and delivery-log inspection.
277
-
278
- What notifkit does not have: an in-app notification center or inbox component, a web dashboard for non-engineers, digest aggregation, or Novu's provider catalog. If you need those, Novu is the better fit.
279
-
280
268
  ## Agent-operable
281
269
 
282
270
  https://github.com/user-attachments/assets/4dff98bb-37d3-44b4-bf46-9607c1cd89b5