explaingit

mrs4s/go-cqhttp

10,667GoAudience · developerComplexity · 3/5Setup · hard

TLDR

A Go-based QQ bot framework implementing the OneBot standard that once let developers build bots for the Chinese messaging platform QQ, the project is abandoned and no longer works due to Tencent protocol changes.

Mindmap

mindmap
  root((go-cqhttp))
    What it does
      QQ bot framework
      OneBot standard
      Abandoned project
    Tech Stack
      Go single binary
      HTTP API
      WebSocket events
    Use Cases
      Study bot design
      OneBot reference
      Go binary patterns
    Status
      No longer maintained
      Protocol blocked
      Migrate to NTQQ
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Study how a QQ bot framework implemented the OneBot standard using HTTP and WebSocket connections

USE CASE 2

Reference the Go codebase for patterns in building a cross-platform single-binary chat bot API

USE CASE 3

Understand WebSocket-based event streaming as an architectural pattern for messaging platform bots

Tech stack

GoWebSocketHTTP

Getting it running

Difficulty · hard Time to first run · 1day+

Project is abandoned, Tencent blocked the reverse-engineered QQ protocol it relied on, not usable for new bots.

In plain English

Go-cqhttp is a bot framework for QQ, the large Chinese messaging platform operated by Tencent. It lets developers write automated bots that can send and receive messages in QQ private chats and group chats, respond to events like people joining a group, manage group settings, and handle friend requests, all through a programming interface rather than the QQ app itself. The project implements a standard called OneBot, which is a shared specification for QQ bot APIs. Because go-cqhttp follows that standard, bot code written for other OneBot-compatible tools can generally work with go-cqhttp without being rewritten. The interface supports HTTP, WebSocket in both directions, and webhook-style event posting, so bots can be built in almost any programming language. Beyond the base OneBot standard, go-cqhttp added a number of extensions: sending image messages, voice and video messages, red envelope handling, forwarding merged conversations, text-to-speech conversion, and proxy-fetched images. Bots can also modify group names, recall messages, and connect to multiple reporting endpoints at once. Important note from the README: the project has been abandoned and is no longer maintained. Tencent progressively blocked the reverse-engineered QQ protocol this project relied on by updating encryption and authentication schemes. The authors state they can no longer keep up, and they recommend developers move to newer approaches based on the official NTQQ client. The project's issue tracker links to migration guidance. Go-cqhttp was written in Go, which made it lightweight and easy to compile as a single binary that runs on Windows, macOS, and Linux without extra dependencies. It was widely used in the Chinese developer community for several years before the underlying protocol access was closed off.

Copy-paste prompts

Prompt 1
Help me understand how go-cqhttp implemented the OneBot standard using HTTP and WebSocket connections so I can apply the same pattern to a new bot framework.
Prompt 2
Show me the go-cqhttp message event structure so I can understand how incoming QQ messages were parsed and routed to bot handlers.
Prompt 3
What Go patterns did go-cqhttp use to compile a single cross-platform binary that runs on Windows, macOS, and Linux without extra dependencies?
Open on GitHub → Explain another repo

← mrs4s on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.