DMWork

DMWork channel plugin for OpenClaw via WuKongIM WebSocket. Enterprise IM integration.

DMWork is an OpenClaw channel plugin that connects to the DMWork enterprise instant messaging platform via the DMWORK WebSocket protocol. Built on top of WuKongIM — a high-performance distributed IM system refined over 10 years (2015-2025) — DMWork brings AI agent capabilities to enterprise IM environments popular in Chinese organizations. The plugin uses DMWORK's custom protocol with DH key exchange and AES-CBC encryption for secure real-time message delivery. The plugin architecture connects OpenClaw to DMWork through WebSocket-based real-time messaging with automatic reconnection, streaming response support, typing indicators, and read receipts. Bot creation follows a BotFather pattern similar to Telegram — you send /newbot or /quickstart to BotFather within DMWork to create your bot and receive a token (bf_ prefix). The plugin auto-registers with the DMWork server via REST API on startup and maintains a persistent WebSocket connection for message receiving. As part of the dmwork-adapters monorepo (which also includes a Claude Code adapter), this plugin follows OpenClaw's standard channel plugin architecture with full lifecycle integration — register, config hot-reload, and multi-account support. With 768 weekly downloads, it's one of the more popular community channel plugins, reflecting strong demand for AI integration in Chinese enterprise messaging environments. Ideal for organizations using DMWork/WuKongIM for internal communications who want to add AI assistant capabilities without migrating to a different platform. The self-hosted nature of WuKongIM makes it particularly attractive for enterprises with data sovereignty requirements. Not recommended unless you're already running a DMWork/WuKongIM server.

Tags: channel, messaging, enterprise

Use Cases

  • Chinese enterprise organizations adding AI assistants to their DMWork internal messaging
  • Self-hosted IM deployments wanting AI capabilities with full data sovereignty
  • IoT environments using WuKongIM for device communication with AI agent integration
  • Customer service bots deployed within DMWork enterprise channels
  • Teams needing AI assistants in a secure, encrypted messaging environment

Tips

  • Let wsUrl auto-detect from the register API response unless you have custom networking requirements
  • Use /quickstart in BotFather for faster bot creation vs the full /newbot flow
  • Monitor WebSocket connection stability — auto-reconnect handles disconnections but logs may help debug
  • Set up the apiUrl to point to your DMWork server's REST API port (default 8090)
  • Check the dmwork-adapters monorepo for the Claude Code adapter if you need both OpenClaw and Claude Code integration
  • Use streaming responses for better user experience in long AI responses

Known Issues & Gotchas

  • Installation is manual — clone the repo and copy to ~/.openclaw/extensions/dmwork
  • Bot token uses bf_ prefix — different from Telegram or Discord token formats
  • wsUrl is auto-detected from the register API call if omitted — but set it explicitly for reliability
  • The plugin sends a greeting to the bot owner on connect — this may be unexpected
  • To disconnect the bot, send /disconnect to BotFather in DMWork (invalidates the IM token and kicks WebSocket)
  • Multi-account configuration uses channels.dmwork.accounts — not multiple channel blocks
  • Documentation and README are primarily in Chinese

Alternatives

  • Feishu/Lark
  • Telegram
  • WeChat (via plugin)

Community Feedback

DMWork 即时通讯平台的 AI 适配器集合 — a collection of AI adapters for the DMWork instant messaging platform, enabling AI agents and chatbots to communicate via the DMWork Bot API.

— GitHub

More than just IM. Supports instant messaging, notifications, messaging middleware, IoT communication, audio/video signaling, live streaming comments, and AI communication.

— GitHub (WuKongIM)

The ecosystem is bigger than you think — there are channel plugins for platforms most people haven't heard of, including regional enterprise IM platforms like DMWork.

— Reddit r/openclaw

Frequently Asked Questions

What is DMWork and WuKongIM?

WuKongIM is a high-performance open-source distributed instant messaging system developed over 10 years. DMWork is an enterprise IM platform built on WuKongIM, popular in Chinese organizations for internal communications with features like end-to-end encryption and IoT support.

How do I create a bot in DMWork?

Send /newbot or /quickstart to BotFather within the DMWork app. This creates a bot and gives you a token with a bf_ prefix. Use this token in your OpenClaw configuration.

Why is the installation manual instead of using openclaw plugins install?

The plugin is distributed as part of the dmwork-adapters monorepo and needs to be installed as an OpenClaw extension (copied to ~/.openclaw/extensions/dmwork) rather than through the standard npm plugin registry.

Is the DMWORK protocol secure?

Yes. The DMWORK protocol uses DH key exchange for key negotiation and AES-CBC encryption for message content. This provides end-to-end encryption between the bot and the DMWork server.

Can I disconnect or remove my bot?

Send /disconnect to BotFather in DMWork. This invalidates the current IM token and kicks the WebSocket connection. You can then create a new bot or reconnect with a fresh token.

Does this plugin support group chats?

Yes. The plugin supports both direct messages and group chats through DMWork's channel system. It also supports multi-account configuration via channels.dmwork.accounts for running multiple bots.

Configuration Examples

Manual Installation

git clone https://github.com/yujiawei/dmwork-adapters.git
cp -r dmwork-adapters/openclaw-channel-dmwork ~/.openclaw/extensions/dmwork
cd ~/.openclaw/extensions/dmwork && npm install

Basic Configuration

# In ~/.openclaw/config.yaml:
channels:
  dmwork:
    botToken: "bf_your_token_here"
    apiUrl: "http://192.168.1.100:8090"
    # wsUrl auto-detected if omitted

Multi-Account Setup

channels:
  dmwork:
    accounts:
      - botToken: "bf_bot1_token"
        apiUrl: "http://server1:8090"
      - botToken: "bf_bot2_token"
        apiUrl: "http://server2:8090"

Installation

openclaw plugins install openclaw-channel-dmwork