npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

n8n-nodes-boltx-nats

v0.1.0

Published

n8n community node — NATS publish + trigger. Khớp type với goworker custom executor.

Downloads

51

Readme

n8n-nodes-boltx-nats

Community node n8n cho NATS publish + trigger. Type khớp 1-1 với executor native bên goworker:

  • n8n-nodes-boltx-nats.nats → publish 1 message (worker: node_nats.go)
  • n8n-nodes-boltx-nats.natsTrigger → subscribe subject (worker: node_nats_trigger.go)

Workflow viết 1 lần chạy đúng trên cả 2 runtime:

  • n8n native (UI test / dev) → execute bằng nats.js (npm nats v2).
  • goworker production → execute bằng github.com/nats-io/nats.go Go native, kết nối pooled qua nats_ops.go.

Cài lên n8n self-host

Option A — Community Nodes UI (npm)

  1. cd worker/node-raw/n8n-nodes-boltx-nats && npm install --ignore-scripts && npm run build && npm publish --access public.
  2. Trên n8n UI → Settings → Community Nodes → Install → paste n8n-nodes-boltx-nats → Install.
  3. Restart n8n nếu cần. Node palette hiện:
    • "NATS (BoltX)" (publish, category Communication)
    • "NATS Trigger (BoltX)" (subscribe trigger)

Option B — Mount thủ công

npm install --prefix ~/.n8n/nodes n8n-nodes-boltx-nats

Restart n8n.

Credential natsApi

Compat với Synadia (url) + LuxChanLu (servers) — worker đọc cả 2 field:

| Field | Mục đích | |---|---| | url | NATS server URL (nats://user:pass@host:4222). Ưu tiên hơn servers. | | username / user | Auth user (worker đọc cả 2). | | password / pass | Auth pass. | | token | NATS auth token. Ưu tiên hơn user/pass khi cả 2 cùng có. |

⚠️ goworker env override: nếu GO_NATS env set trên worker, worker bỏ qua credential trên node → dùng URL của env. n8n native vẫn dùng credential bình thường.

Param khớp worker

Publish nats (Nats.node.ts)

| Param n8n | Field worker | |---|---| | subject | subject (bắt buộc) | | data | data (default ={{ $json }} → worker fast-path bypass expression eval) |

Output: pass-through input items (worker behaviour).

Trigger natsTrigger (NatsTrigger.node.ts)

| Param n8n | Mục đích | |---|---| | subject | Subject subscribe (hỗ trợ wildcard *>) | | queueGroup | Optional, queue group cho load-balance | | parseJson | Bật → JSON.parse payload, lỗi → giữ raw string |

Emit shape: { subject, reply, sid, data }.

⚠️ Trên goworker, NatsTriggerNode.Execute chỉ passthrough — logic subscribe thực hiện ngoài (internal/transport/...) đọc descriptor để subscribe đúng subject/queue.

Async publish flag

Khi worker chạy với GO_NATS_ASYNC=1, publish thành fire-and-forget (không chờ ACK). Param descriptor n8n không expose flag này — chỉnh ở env worker production.

Build local

npm install --ignore-scripts    # bỏ qua native compile của transitive deps
npm run build                   # tsc + gulp copy icons → dist/
npm run dev                     # tsc --watch