@wesell/n8n-nodes-confirmx
v0.3.0
Published
n8n community nodes for the ConfirmX WhatsApp Business Platform Public REST API. Ships a Message node (start conversation with a template, send text/media), a ConfirmX AI Agent tool node, and a ConfirmX Chat Model node usable as the Chat Model of n8n's AI
Maintainers
Readme
@wesell/n8n-nodes-confirmx
n8n community nodes for the ConfirmX WhatsApp Business Platform. Wraps the public REST API at /api/v1/* and exposes each operation as both a regular n8n action and an AI-callable tool for n8n's AI Agent node.
What's included
| Node | Operations | AI tool? | | --- | --- | --- | | ConfirmX Message | Start Conversation (send template), Send Text, Send Media | all 3 | | ConfirmX AI Agent | Run ConfirmX's server-side AI agent over a payload | ✅ | | ConfirmX Chat Model | Chat Model sub-node for the AI Agent / LLM Chain nodes | — (it IS the model) |
The ConfirmX AI Agent node has usableAsTool: true, so n8n's native AI Agent node can attach it as a tool and delegate subtasks (order-confirmation reasoning, field extraction, fuzzy matching) to ConfirmX's own agent runtime. It calls POST /api/v1/ai-agent/run, uses the org's default LLM provider unless you pin one, and is metered by token usage against the org wallet.
ConfirmX Chat Model
The ConfirmX Chat Model node plugs into the Chat Model socket of n8n's AI Agent (and LLM Chain) nodes — pick it instead of "OpenAI Chat Model" etc. n8n drives the agent loop; every completion goes through ConfirmX's OpenAI-compatible endpoint (POST /api/v1/llm/chat/completions), which proxies to whichever LLM provider backs the platform (OpenAI / Anthropic / Google) and meters each call against the org wallet by token usage.
- Tool calling is fully supported — the AI Agent's attached tools work as usual.
- Provider: platform default, or pin one via the LLM Provider ID field.
- Model: provider default, or override via the Model field.
- Scope: the API key needs
llm:chat(orai_agent:run, or*). - Streaming is not supported — the model falls back to request/response transparently.
Setup
- In ConfirmX: Settings → API Keys → Create. Copy the key (
cfx_live_…for production,cfx_test_…for local). - In n8n: Settings → Community Nodes → Install → pick
@confirmx/n8n-nodes-confirmx. - Add the ConfirmX API credential: paste your key + the base URL (
https://app.confirmx.com/api/v1orhttp://localhost:3001/api/v1). - Drop any ConfirmX node into your flow.
Local install (for development)
git clone https://github.com/ConfirmX/n8n-nodes-confirmx
cd n8n-nodes-confirmx
npm install
npm run build
npm link
# in your n8n home:
npm link @wesell/n8n-nodes-confirmx
# restart n8nUsing as AI Agent tools
Every node with usableAsTool: true shows up in n8n's AI Agent "Tools" picker. The descriptions are written in-house to be LLM-friendly — they tell the model when to use the tool, what params it needs, and what it returns. Examples:
- Send Text: "Send a free-form text message in an existing conversation. Use ONLY when the conversation is open (within 24h of the customer's last inbound message); otherwise use
startConversationwith a template." - ConfirmX AI Agent: "Delegate a task to ConfirmX's server-side AI agent. Give it a system prompt and an input payload; it runs a tool-enabled reasoning loop and returns
output(JSON when an Output Schema is given, else text) plus tokenusage."
Scopes
The ConfirmX API key you paste must have the appropriate scope(s). The scope picker in ConfirmX exposes templates:read|write, conversations:read|write, messages:read|write, webhooks:read|write, shipping_zones:read, ai_agent:run, llm:chat, plus * (full org access). The Message node needs messages:write; the AI Agent node needs ai_agent:run; the Chat Model node needs llm:chat (all included in *).
Billing
The ConfirmX API metered every v1 call against the org's wallet:
- Writes (POST/PUT/PATCH/DELETE): metered (default $0.0005) — e.g. sending a message.
- AI Agent runs: metered by token usage (prompt + completion) against the provider's price catalog, not the flat write price.
- Chat Model completions: metered by token usage per completion — an agent loop with 3 model calls = 3 debits.
When the wallet runs low, the API returns 402 Payment Required. The n8n node surfaces this as a NodeOperationError with the balance figures and the topup URL inline.
What this package does NOT include
- Template / conversation / account / webhook CRUD nodes (use the REST API directly).
- A ConfirmX webhook trigger (inbound events) — this build is send + AI-agent only.
- E-commerce platform integrations — separate concern.
License
MIT © ConfirmX
