n8n-nodes-zalo-user-noti
v1.0.0
Published
n8n node for Zalo personal account automation using zca-js
Downloads
13
Maintainers
Readme
n8n-nodes-zalo-user-noti

Unofficial n8n community node for Zalo personal account automation using zca-js.
⚠️ Warning: Using this node could get your Zalo account locked or banned. Use at your own risk.
Features
📨 Message Operations
- Send text messages (with quote/reply, mentions)
- Send links with preview
- Send voice messages
- Send video messages
- Send contact cards
- Send bank cards
- Forward messages
- Delete/Undo messages
- Add reactions
- Send typing/seen events
👥 Friend Operations
- Get all friends
- Get user info
- Find user by phone number
- Send/Accept/Cancel friend requests
- Block/Unblock users
- Change friend aliases
- Check last online time
👨👩👧👦 Group Operations
- Create/Manage groups
- Add/Remove members
- Add/Remove deputies
- Block/Unblock members
- Enable/Disable invite links
- Join group by link
- Review pending requests
- Update group settings
🎨 Sticker Operations
- Search stickers
- Get sticker details
- Send stickers
📊 Poll Operations
- Create polls
- Get poll details
- Lock polls
⏰ Reminder Operations
- Create/Edit/Remove reminders
- Get reminder list and responses
💬 Conversation Operations
- Pin/Unpin conversations
- Hide conversations
- Mute/Unmute
- Mark as unread
- Set auto-delete timer
👤 Account Operations
- Get account info
- Update profile
- Change avatar
- Manage labels
⚡ Quick Message & Auto Reply
- Manage quick messages
- Create auto-reply rules
🛒 Catalog Operations (ZBusiness)
- Manage catalogs
- Create/Update/Delete products
📡 Trigger Events
- New message (User/Group)
- Reactions
- Message undo/recall
- Group events (join, leave, kick, etc.)
Installation
Cách 1: Cài đặt từ npm (Khuyến nghị)
Sau khi publish lên npm, bạn có thể cài đặt qua Community Nodes:
- Mở n8n → Settings → Community Nodes
- Click Install a community node
- Nhập
n8n-nodes-zalo-user-noti - Click Install
Cách 2: Cài đặt thủ công (Manual Installation)
Bước 1: Chuẩn bị thư mục
Trên Linux/macOS:
# Tạo thư mục custom nodes nếu chưa có
mkdir -p ~/.n8n/customTrên Windows:
# Mở PowerShell và chạy
mkdir $env:USERPROFILE\.n8n\customNếu dùng Docker:
# Tạo thư mục trên host
mkdir -p /path/to/n8n-data/customBước 2: Clone/Download và Build
# Clone repository
git clone https://github.com/notivn/n8n-nodes-zalo-user-noti.git
cd n8n-nodes-zalo-user-noti
# Cài đặt dependencies
npm install
# Build project
npm run buildBước 3: Copy vào n8n
Trên Linux/macOS:
# Copy toàn bộ package (không chỉ dist)
cp -r . ~/.n8n/custom/n8n-nodes-zalo-user-notiTrên Windows:
# Copy toàn bộ folder
xcopy /E /I . %USERPROFILE%\.n8n\custom\n8n-nodes-zalo-user-notiNếu dùng Docker: thêm volume mount trong docker-compose.yml:
services:
n8n:
image: n8nio/n8n
volumes:
- /path/to/n8n-data:/home/node/.n8n
- /path/to/n8n-nodes-zalo-user-noti:/home/node/.n8n/custom/n8n-nodes-zalo-user-noti
environment:
- N8N_CUSTOM_EXTENSIONS=/home/node/.n8n/customBước 4: Cấu hình n8n để load custom nodes
Thêm biến môi trường:
Linux/macOS (~/.bashrc hoặc ~/.zshrc):
export N8N_CUSTOM_EXTENSIONS="~/.n8n/custom"Windows (Environment Variables):
N8N_CUSTOM_EXTENSIONS=%USERPROFILE%\.n8n\customDocker (docker-compose.yml):
environment:
- N8N_CUSTOM_EXTENSIONS=/home/node/.n8n/customBước 5: Restart n8n
# Nếu chạy trực tiếp
# Ctrl+C để stop, rồi chạy lại
n8n start
# Nếu dùng Docker
docker-compose restart n8n
# Nếu dùng PM2
pm2 restart n8nBước 6: Kiểm tra
- Mở n8n trong browser
- Tạo workflow mới
- Tìm kiếm "Zalo" trong nodes panel
- Bạn sẽ thấy Zalo User và Zalo Trigger
Cách 3: Link trực tiếp (Development)
Phù hợp khi đang phát triển/debug:
# Trong thư mục project
npm link
# Link vào n8n
cd ~/.n8n
npm link n8n-nodes-zalo-user-notiTroubleshooting
Node không hiển thị:
- Kiểm tra logs:
n8n startvà xem có lỗi gì không - Đảm bảo đã build: kiểm tra folder
dist/có tồn tại - Kiểm tra biến môi trường
N8N_CUSTOM_EXTENSIONS
Lỗi "Cannot find module":
cd ~/.n8n/custom/n8n-nodes-zalo-user-noti
npm installLỗi TypeScript:
npm run buildCredentials Setup
You need to extract credentials from Zalo Web:
- Install the ZaloDataExtractor browser extension
- Open Zalo Web and log in
- Click the extension to extract:
- IMEI
- Cookie
- User Agent
- Add these to your n8n credentials
Credential Fields
| Field | Description | |-------|-------------| | IMEI | Device IMEI from Zalo Web | | Cookie | Full cookie string | | User Agent | Browser user agent | | Proxy URL | Optional proxy (http://user:pass@host:port) |
Usage Examples
Send a Message
Resource: Message
Operation: Send Text
Thread Type: User
Thread ID: <user_id>
Message: Hello from n8n!Echo Bot with Trigger
Add Zalo Trigger node
- Event: New Message
- Filter: Ignore Self Messages ✓
Connect to Zalo User node
- Resource: Message
- Operation: Send Text
- Thread ID:
{{ $json.threadId }} - Message:
Echo: {{ $json.content }}
Auto-Welcome New Group Members
Add Zalo Trigger node
- Event: Group Event
- Group Event Types: Member Join
Connect to Zalo User node
- Resource: Message
- Operation: Send Text
- Thread Type: Group
- Thread ID:
{{ $json.groupId }} - Message:
Welcome to the group!
Important Notes
Single Listener Limitation: Only one listener can run per account at a time. If you open Zalo Web while the trigger is active, the trigger will stop.
Session Management: Cookies may expire. Re-extract credentials if you get authentication errors.
Rate Limiting: Zalo may rate-limit requests. Add delays between operations if needed.
Account Safety: Use a secondary account for testing to avoid bans.
