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

@wflclaw/openclaw-channel

v1.0.9

Published

OpenClaw channel plugin for AI Staff Center (WFL Claw)

Readme

WFL Claw - OpenClaw Channel Plugin

AI Staff Center WebSocket channel plugin for OpenClaw.

Installation

方式一:npm pack 安装(推荐 ⭐)

# 1. 创建插件目录
mkdir -p ~/.openclaw/extensions/wflclaw
cd ~/.openclaw/extensions/wflclaw

# 2. 下载并解压 npm 包
npm pack @wflclaw/openclaw-channel
tar -xzf wflclaw-openclaw-channel-*.tgz --strip-components=1
rm wflclaw-openclaw-channel-*.tgz

# 3. 安装依赖
npm install --production

方式二:从源码安装

cd /path/to/openclaw-plugin
npm install
npm run build
npm publish --access public
# 然后按方式一安装

Configuration

Method 1: Remote Config File (推荐 ⭐)

从服务器动态读取配置文件,配置更新无需重启 OpenClaw。

环境变量方式:

export WFLCLAW_CONFIG_URL=https://clawde.shwfl.edu.cn/api/v1/plugin/config/4
# 或者使用默认的 employee_id
export AI_STAFF_EMPLOYEE_ID=4

远程配置文件格式(服务器端):

{
  "url": "wss://clawde.shwfl.edu.cn/ws/bot",
  "token": "YOUR_BOT_TOKEN",
  "enabled": true,
  "reconnect": true,
  "reconnectInterval": 5000
}

优势:

  • ✅ 配置集中管理
  • ✅ 支持热更新(定期重新 fetch)
  • ✅ 适合大规模部署
  • ✅ 与后端 API 集成

Method 2: OpenClaw Config File

~/.openclaw/openclaw.json 中添加或修改配置:

方式 A: 使用快速配置脚本(推荐 ⭐)

# 自动合并配置,不会影响其他渠道
bash configure-wflclaw.sh YOUR_BOT_TOKEN clawde.shwfl.edu.cn

方式 B: 手动编辑配置文件

# 1. 备份现有配置
cp ~/.openclaw/openclaw.json ~/.openclaw/openclaw.json.backup

# 2. 编辑配置文件
vi ~/.openclaw/openclaw.json

# 3. 在 channels 中添加 wflclaw(保留其他渠道配置)
{
  "channels": {
    "feishu": { ... },  // ← 保留现有配置
    "telegram": { ... },  // ← 保留现有配置
    "wflclaw": {  // ← 新增(注意:渠道名必须是 wflclaw)
      "enable": true,
      "token": "YOUR_BOT_TOKEN",
      "domain": "clawde.shwfl.edu.cn"
    }
  }
}

⚠️ 重要提示:

  • ❌ 不要直接覆盖整个文件,会丢失其他渠道配置
  • ✅ 应该在现有的 channels 对象中添加 wflclaw
  • ✅ 使用 configure-wflclaw.sh 脚本会自动合并配置
  • ✅ 渠道名必须使用 wflclaw(与插件内部声明一致)
{
  "channels": {
    "wflclaw": {
      "enable": true,
      "token": "YOUR_BOT_TOKEN",
      "domain": "clawde.shwfl.edu.cn"
    }
  }
}

或者使用完整的 URL:

{
  "channels": {
    "wflclaw": {
      "enable": true,
      "token": "YOUR_BOT_TOKEN",
      "url": "wss://clawde.shwfl.edu.cn/ws/bot"
    }
  }
}

支持的配置项:

  • enable / enabled: 是否启用(布尔值)
  • token: Bot Token(必填)
  • url / wsUrl: 完整的 WebSocket URL(选填,与 domain 二选一)
  • domain: 域名,会自动拼接为 wss://{domain}/ws/bot(选填,与 url 二选一)
  • reconnect: 是否自动重连(可选,默认 true)
  • reconnectInterval: 重连间隔毫秒数(可选,默认 5000)

Method 3: Environment Variables

插件会自动从以下端点获取配置:

GET /api/v1/plugin/config/{employee_id}

Method 4: Manual Configuration

也可以在 OpenClaw 配置文件中手动指定:

{
  "channels": {
    "wflclaw": {
      "url": "wss://clawde.shwfl.edu.cn/ws/bot",
      "token": "YOUR_BOT_TOKEN",
      "enabled": true
    }
  }
}

Usage

安装后,在 OpenClaw 的 config.json 中启用即可自动连接。

Development

npm install
npm run build
npm run dev  # watch mode

License

MIT