NapCatQQ
Modern protocol-side framework based on NTQQ
NapCatQQ is a low-memory framework for building automated bots on QQ, China's major messaging platform, implementing the OneBot 11 standard so bot code works across multiple QQ backends without changes.
NapCatQQ is a framework for building automated bots on QQ, the large Chinese social messaging platform owned by Tencent. It works by implementing a bot protocol on top of NTQQ, which is QQ's modern client version. The protocol it implements is called OneBot 11, a community-standard interface that lets bot developers write their logic once and have it run across multiple QQ bot backends without changes.
The project is written in TypeScript and is designed to run with low memory usage over long periods, making it practical to host on modest hardware. It exposes a rich API that covers most of the standard OneBot interface, including sending and receiving messages, managing groups, and handling events. A web-based UI is included for configuration and monitoring.
In version 4.8.115 the project added support for a streaming API, which addresses problems with uploading and downloading large media files in Docker environments or across different devices. It also switched to using string types for message, user, and group IDs, which avoids integer overflow problems that JavaScript has when handling large 64-bit numbers.
The README is mostly in Chinese. The project maintains several community groups on QQ itself and a Telegram channel. Documentation is hosted on multiple mirrors for reliability. The license is described as a mixed open-source license: third-party library code follows its original licenses, and the project-specific code uses the license in the repository. The README explicitly states that the project is non-commercial and that users are responsible for complying with local laws.
Where it fits
- Build a QQ group management bot that auto-replies to messages and handles group events using the OneBot 11 API.
- Create a long-running QQ bot on modest hardware that streams large media files to and from group chats.
- Develop a QQ automation bot that manages users and group settings through a web-based configuration UI.
- Write OneBot 11-compatible bot logic that can switch QQ backends without rewriting your code.