2026-01-16 13:28:18 -08:00
---
2026-03-02 15:40:46 +00:00
summary: "Zalo personal account support via native zca-js (QR login), capabilities, and configuration"
2026-01-16 13:28:18 -08:00
read_when:
2026-01-30 03:15:10 +01:00
- Setting up Zalo Personal for OpenClaw
2026-01-16 13:28:18 -08:00
- Debugging Zalo Personal login or message flow
2026-01-31 16:04:03 -05:00
title: "Zalo Personal"
2026-01-16 13:28:18 -08:00
---
2026-01-31 21:13:13 +09:00
2026-01-16 13:28:18 -08:00
# Zalo Personal (unofficial)
2026-03-02 15:40:46 +00:00
Status: experimental. This integration automates a **personal Zalo account** via native `zca-js` inside OpenClaw.
2026-01-16 13:28:18 -08:00
> **Warning:** This is an unofficial integration and may result in account suspension/ban. Use at your own risk.
## Plugin required
2026-01-31 21:13:13 +09:00
2026-01-16 13:28:18 -08:00
Zalo Personal ships as a plugin and is not bundled with the core install.
2026-01-31 21:13:13 +09:00
2026-01-30 03:15:10 +01:00
- Install via CLI: `openclaw plugins install @openclaw/zalouser`
- Or from a source checkout: `openclaw plugins install ./extensions/zalouser`
2026-02-07 15:40:35 -05:00
- Details: [Plugins ](/tools/plugin )
2026-01-16 13:28:18 -08:00
2026-03-02 15:40:46 +00:00
No external `zca` /`openzca` CLI binary is required.
2026-01-16 13:28:18 -08:00
2026-02-21 11:18:29 -05:00
## Quick setup (beginner)
2026-01-31 21:13:13 +09:00
1. Install the plugin (see above).
2. Login (QR, on the Gateway machine):
2026-01-30 03:15:10 +01:00
- `openclaw channels login --channel zalouser`
2026-03-02 15:40:46 +00:00
- Scan the QR code with the Zalo mobile app.
2026-01-31 21:13:13 +09:00
3. Enable the channel:
2026-01-16 13:28:18 -08:00
```json5
{
channels: {
zalouser: {
enabled: true,
2026-01-31 21:13:13 +09:00
dmPolicy: "pairing",
},
},
2026-01-16 13:28:18 -08:00
}
```
2026-02-06 10:00:08 -05:00
4. Restart the Gateway (or finish onboarding).
5. DM access defaults to pairing; approve the pairing code on first contact.
2026-01-16 13:28:18 -08:00
## What it is
2026-01-31 21:13:13 +09:00
2026-03-02 15:40:46 +00:00
- Runs entirely in-process via `zca-js` .
- Uses native event listeners to receive inbound messages.
- Sends replies directly through the JS API (text/media/link).
2026-01-16 13:28:18 -08:00
- Designed for “personal account” use cases where Zalo Bot API is not available.
## Naming
2026-01-31 21:13:13 +09:00
2026-01-16 13:28:18 -08:00
Channel id is `zalouser` to make it explicit this automates a **personal Zalo user account** (unofficial). We keep `zalo` reserved for a potential future official Zalo API integration.
## Finding IDs (directory)
2026-01-31 21:13:13 +09:00
2026-01-16 13:28:18 -08:00
Use the directory CLI to discover peers/groups and their IDs:
```bash
2026-01-30 03:15:10 +01:00
openclaw directory self --channel zalouser
openclaw directory peers list --channel zalouser --query "name"
openclaw directory groups list --channel zalouser --query "work"
2026-01-16 13:28:18 -08:00
```
## Limits
2026-01-31 21:13:13 +09:00
2026-01-16 13:28:18 -08:00
- Outbound text is chunked to ~2000 characters (Zalo client limits).
- Streaming is blocked by default.
## Access control (DMs)
2026-01-31 21:13:13 +09:00
2026-01-16 13:28:18 -08:00
`channels.zalouser.dmPolicy` supports: `pairing | allowlist | open | disabled` (default: `pairing` ).
2026-03-02 15:40:46 +00:00
`channels.zalouser.allowFrom` accepts user IDs or names. During onboarding, names are resolved to IDs using the plugin's in-process contact lookup.
2026-01-16 13:28:18 -08:00
Approve via:
2026-01-31 21:13:13 +09:00
2026-01-30 03:15:10 +01:00
- `openclaw pairing list zalouser`
- `openclaw pairing approve zalouser <code>`
2026-01-16 13:28:18 -08:00
2026-01-18 00:41:57 +00:00
## Group access (optional)
2026-01-31 21:13:13 +09:00
2026-01-18 00:41:57 +00:00
- Default: `channels.zalouser.groupPolicy = "open"` (groups allowed). Use `channels.defaults.groupPolicy` to override the default when unset.
- Restrict to an allowlist with:
- `channels.zalouser.groupPolicy = "allowlist"`
2026-03-13 01:31:08 +00:00
- `channels.zalouser.groups` (keys should be stable group IDs; names are resolved to IDs on startup when possible)
2026-03-08 04:48:05 +00:00
- `channels.zalouser.groupAllowFrom` (controls which senders in allowed groups can trigger the bot)
2026-01-18 00:41:57 +00:00
- Block all groups: `channels.zalouser.groupPolicy = "disabled"` .
- The configure wizard can prompt for group allowlists.
2026-03-13 01:31:08 +00:00
- On startup, OpenClaw resolves group/user names in allowlists to IDs and logs the mapping.
- Group allowlist matching is ID-only by default. Unresolved names are ignored for auth unless `channels.zalouser.dangerouslyAllowNameMatching: true` is enabled.
- `channels.zalouser.dangerouslyAllowNameMatching: true` is a break-glass compatibility mode that re-enables mutable group-name matching.
2026-03-08 04:48:05 +00:00
- If `groupAllowFrom` is unset, runtime falls back to `allowFrom` for group sender checks.
- Sender checks apply to both normal group messages and control commands (for example `/new` , `/reset` ).
2026-01-18 00:41:57 +00:00
Example:
2026-01-31 21:13:13 +09:00
2026-01-18 00:41:57 +00:00
```json5
{
channels: {
zalouser: {
groupPolicy: "allowlist",
2026-03-08 04:48:05 +00:00
groupAllowFrom: ["1471383327500481391"],
2026-01-18 00:41:57 +00:00
groups: {
"123456789": { allow: true },
2026-01-31 21:13:13 +09:00
"Work Chat": { allow: true },
},
},
},
2026-01-18 00:41:57 +00:00
}
```
2026-03-02 22:08:01 +00:00
### Group mention gating
- `channels.zalouser.groups.<group>.requireMention` controls whether group replies require a mention.
- Resolution order: exact group id/name -> normalized group slug -> `*` -> default (`true` ).
- This applies both to allowlisted groups and open group mode.
2026-03-08 04:48:05 +00:00
- Authorized control commands (for example `/new` ) can bypass mention gating.
- When a group message is skipped because mention is required, OpenClaw stores it as pending group history and includes it on the next processed group message.
- Group history limit defaults to `messages.groupChat.historyLimit` (fallback `50` ). You can override per account with `channels.zalouser.historyLimit` .
2026-03-02 22:08:01 +00:00
Example:
```json5
{
channels: {
zalouser: {
groupPolicy: "allowlist",
groups: {
"*": { allow: true, requireMention: true },
"Work Chat": { allow: true, requireMention: false },
},
},
},
}
```
2026-01-16 13:28:18 -08:00
## Multi-account
2026-01-31 21:13:13 +09:00
2026-03-02 15:40:46 +00:00
Accounts map to `zalouser` profiles in OpenClaw state. Example:
2026-01-16 13:28:18 -08:00
```json5
{
channels: {
zalouser: {
enabled: true,
defaultAccount: "default",
accounts: {
2026-01-31 21:13:13 +09:00
work: { enabled: true, profile: "work" },
},
},
},
2026-01-16 13:28:18 -08:00
}
```
2026-03-02 22:08:01 +00:00
## Typing, reactions, and delivery acknowledgements
- OpenClaw sends a typing event before dispatching a reply (best-effort).
- Message reaction action `react` is supported for `zalouser` in channel actions.
- Use `remove: true` to remove a specific reaction emoji from a message.
- Reaction semantics: [Reactions ](/tools/reactions )
- For inbound messages that include event metadata, OpenClaw sends delivered + seen acknowledgements (best-effort).
2026-01-16 13:28:18 -08:00
## Troubleshooting
2026-03-02 15:40:46 +00:00
**Login doesn't stick:**
2026-01-31 21:13:13 +09:00
2026-01-30 03:15:10 +01:00
- `openclaw channels status --probe`
- Re-login: `openclaw channels logout --channel zalouser && openclaw channels login --channel zalouser`
2026-03-02 15:40:46 +00:00
**Allowlist/group name didn't resolve:**
2026-03-08 04:48:05 +00:00
- Use numeric IDs in `allowFrom` /`groupAllowFrom` /`groups` , or exact friend/group names.
2026-03-02 15:40:46 +00:00
**Upgraded from old CLI-based setup:**
- Remove any old external `zca` process assumptions.
- The channel now runs fully in OpenClaw without external CLI binaries.