Connect your AI assistant to QQ — private chat, group chat, and rich media, all in one plugin.
简体中文 | English
Scan to join the QQ group chat
| Feature | Description |
|---|---|
| 🔒 Multi-Scene | C2C private chat, group @messages, channel messages, channel DMs |
| 🖼️ Rich Media | Send & receive images, voice, video, and files |
| 🎙️ Voice (STT/TTS) | Speech-to-text transcription & text-to-speech replies |
| ⏰ Scheduled Push | Proactive message delivery via scheduled tasks |
| 🔗 URL Support | Direct URL sending in private chat (no restrictions) |
| ⌨️ Typing Indicator | "Bot is typing..." status shown in real-time |
| 🔄 Hot Reload | Install via npm with seamless hot updates |
| 📝 Markdown | Full Markdown formatting support |
| 🛠️ Commands | Native OpenClaw command integration |
Note: This plugin serves as a message channel only — it relays messages between QQ and OpenClaw. Capabilities like image understanding, voice transcription, drawing, etc. depend on the AI model you configure and the skills installed in OpenClaw, not on this plugin itself.
You: (send a voice message) "What's the weather like tomorrow in Shenzhen?"
QQBot: Tomorrow (March 7, Saturday) Shenzhen weather forecast 🌤️ ...
You: (send a TXT file of "War and Peace")
QQBot: Got it! You uploaded the Chinese version of "War and Peace" by Leo Tolstoy. This appears to be the opening of Chapter 1...
You: (send an image)
QQBot: Haha, so cute! Is that a QQ penguin in a lobster costume? 🦞🐧 ...
You: Draw me a cat
QQBot: Here you go! 🐱
You: Tell me a joke in voice
QQBot: (sends a voice message)
You: Extract chapter 1 of War and Peace and send it as a file
QQBot: (sends a .txt file)
You: Send me a demo video
QQBot: (sends a video)
For a deep dive into rich media capabilities, see the Media Guide.
For a step-by-step walkthrough with screenshots, see the official guide.
⚠️ The bot will automatically appear in your QQ message list and send a first message. However, it will reply "The bot has gone to Mars" until you complete the configuration steps below.
# Via OpenClaw CLI (recommended)
openclaw plugins install @sliverp/qqbot@latest
# Or from source
git clone https://github.com/sliverp/qqbot.git && cd qqbot
openclaw plugins install .
Option 1: CLI Wizard (Recommended)
openclaw channels add --channel qqbot --token "AppID:AppSecret"
Option 2: Edit Config File
Edit ~/.openclaw/openclaw.json:
{
"channels": {
"qqbot": {
"enabled": true,
"appId": "Your AppID",
"clientSecret": "Your AppSecret"
}
}
}
openclaw gateway
Open QQ, find your bot, and send a message!
Run multiple QQ bots under a single OpenClaw instance.
Edit ~/.openclaw/openclaw.json and add an accounts field under channels.qqbot:
{
"channels": {
"qqbot": {
"enabled": true,
"appId": "111111111",
"clientSecret": "secret-of-bot-1",
"accounts": {
"bot2": {
"enabled": true,
"appId": "222222222",
"clientSecret": "secret-of-bot-2"
},
"bot3": {
"enabled": true,
"appId": "333333333",
"clientSecret": "secret-of-bot-3"
}
}
}
}
}
Notes:
appId / clientSecret is the default account (accountId = "default")accounts (e.g. bot2, bot3) is the accountId for that botenabled, name, allowFrom, systemPrompt, etc.accountsAdd a second bot via CLI (if the framework supports the --account parameter):
openclaw channels add --channel qqbot --account bot2 --token "222222222:secret-of-bot-2"
When using openclaw message send, specify which bot to use with the --account parameter:
# Send with the default bot (no --account = uses "default")
openclaw message send --channel "qqbot" \
--target "qqbot:c2c:OPENID" \
--message "hello from default bot"
# Send with bot2
openclaw message send --channel "qqbot" \
--account bot2 \
--target "qqbot:c2c:OPENID" \
--message "hello from bot2"
Target Formats:
| Format | Description |
|---|---|
qqbot:c2c:OPENID | Private chat (C2C) |
qqbot:group:GROUP_OPENID | Group chat |
qqbot:channel:CHANNEL_ID | Guild channel |
⚠️ Important: Each bot has its own set of user OpenIDs. An OpenID received by Bot A cannot be used to send messages via Bot B — this will result in a 500 error. Always use the matching bot's
accountIdto send messages to its users.
openclaw gateway starts, all accounts with enabled: true launch their own WebSocket connectionsappId), preventing cross-contamination[qqbot:accountId] for easy debuggingSTT supports two-level configuration with priority fallback:
| Priority | Config Path | Scope |
|---|---|---|
| 1 (highest) | channels.qqbot.stt | Plugin-specific |
| 2 (fallback) | tools.media.audio.models[0] | Framework-level |
{
"channels": {
"qqbot": {
"stt": {
"provider": "your-provider",
"model": "your-stt-model"
}
}
}
}
provider — references a key in models.providers to inherit baseUrl and apiKeyenabled: false to disable| Priority | Config Path | Scope |
|---|---|---|
| 1 (highest) | channels.qqbot.tts | Plugin-specific |
| 2 (fallback) | messages.tts | Framework-level |
{
"channels": {
"qqbot": {
"tts": {
"provider": "your-provider",
"model": "your-tts-model",
"voice": "your-voice"
}
}
}
}
provider — references a key in models.providers to inherit baseUrl and apiKeyvoice — voice variantenabled: false to disable (default: true)<qqvoice> tags to generate and send voice messagesFor installations via
openclaw plugins install
openclaw plugins upgrade @sliverp/qqbot@latest
npx -y @sliverp/qqbot@latest upgrade
bash ./upgrade-and-run.sh
When no --appid / --secret is provided, the script reads existing config from ~/.openclaw/openclaw.json automatically.
# First-time or override credentials
bash ./upgrade-and-run.sh --appid YOUR_APPID --secret YOUR_SECRET
| Option | Description |
|---|---|
--appid <id> | QQ Bot AppID |
--secret <secret> | QQ Bot AppSecret |
--markdown <yes|no> | Enable Markdown format (default: no) |
-h, --help | Show help |
Environment variables QQBOT_APPID, QQBOT_SECRET, QQBOT_TOKEN (AppID:Secret) are also supported.
bash ./pull-latest.sh
bash ./pull-latest.sh --branch main # specify branch (default: main)
bash ./pull-latest.sh --force # skip prompts, force update
bash ./pull-latest.sh --repo <git-url> # use a different repo
git clone https://github.com/sliverp/qqbot.git && cd qqbot
bash ./scripts/upgrade.sh
openclaw plugins install .
openclaw channels add --channel qqbot --token "AppID:AppSecret"
openclaw gateway restart