Skip to content
AstrBot
Main Navigation HomeBlogRoadmapHTTP API

English

简体中文

English

简体中文

Toggle dark mode

Intro & DeployMessaging PlatformsAI IntegrationUsageDevelopment
Sidebar Navigation

Introduction

What is AstrBot

Community

FAQ

Deployment

Package Manager

One-click Launcher

Docker

Kubernetes

BT Panel

1Panel

Manual

Other Deployments

CasaOS

Compshare GPU

Community-provided Deployment

Support Us

Messaging Platforms

Quick Start

QQ Official Bot

Webhook Method

Websockets Method

WeCom Application

WeCom AI Bot

WeChat Official Account

Lark

DingTalk

Telegram

LINE

Slack

Misskey

Discord

OneBot v11

NapCat

Lagrange

Other Clients

Satori

Using LLOneBot

Using server-satori

Community-provided

Matrix

KOOK

VoceChat

AI Integration

✨ Model Providers

NewAPI

AIHubMix

PPIO Cloud

SiliconFlow

TokenPony

302.AI

Ollama

LMStudio

⚙️ Agent Runners

Built-in Agent Runner

Dify

Coze

Alibaba Bailian

Usage

WebUI

Plugins

Built-in Commands

Tool Use

Anthropic Skills

SubAgent Orchestration

Proactive Tasks

MCP

Web Search

Knowledge Base

Custom Rules

Agent Runner

Unified Webhook Mode

Auto Context Compression

Agent Sandbox

Development

Plugin Development

🌠 Getting Started

Minimal Example

Listen to Message Events

Send Messages

Plugin Configuration

AI

Storage

HTML to Image

Session Control

Publish Plugin

Platform Adapter Integration

AstrBot HTTP API

AstrBot Configuration File

Others

Self-hosted HTML to Image

Open Source Summer

OSPP 2025

On this page

Connect AstrBot to WeChat Official Account Platform ​

AstrBot supports WeChat Official Account integration (version >= v3.5.8). After setup, you can chat with AstrBot directly in the WeChat Official Account chat interface.

Before You Start ​

  1. Open AstrBot Dashboard.
  2. Click Bots in the left sidebar.
  3. Click + Create Bot.
  4. Select weixin_official_account.

A configuration dialog will appear. Keep it open and continue.

Create / Sign In to WeChat Official Account Platform ​

Open WeChat Official Account Platform.

  • If you already have an account, sign in.
  • If not, register a new account and choose Official Account.

NOTE

A newly registered account may require 1-2 days for review before it can be used.

Configure Callback Service ​

Open Settings & Development -> Development Interface Management.

Development Interface Management

Copy AppID and AppSecret from WeChat platform to AstrBot fields appid and secret.

Open IP whitelist and add your public IP(s), one per line if multiple.

In server configuration, click modify.

  • Token: create any string with length 3-32, and fill the same value in AstrBot token.
  • EncodingAESKey: click random generate and fill AstrBot encoding_aes_key.

Keep Unified Webhook Mode (unified_webhook_mode) enabled (recommended), then save AstrBot config and wait for restart.

For URL:

  • If unified mode is enabled, use the unique callback URL generated by AstrBot (from logs or bot card).
  • If unified mode is disabled, use http://<your-domain>/callback/command.

unified_webhook

NOTE

WeChat Official Account callback supports only ports 80 or 443. You usually need a domain and reverse proxy:

  • Unified mode enabled: forward to AstrBot port 6185
  • Unified mode disabled: forward to adapter port 6194

Set message encryption mode to Security Mode.

Wait a moment and click Submit. If configuration is correct, you will see success.

Test ​

In WeChat Official Account platform, open account profile and find your QR code.

Scan it with WeChat, send help, and check whether AstrBot replies.

If it replies, integration is successful.

NOTE

If console shows ip xxxxx not in whitelist, your public IP is not in WeChat whitelist yet. Add it and wait a few minutes for WeChat to refresh.

Reverse Proxy (Custom API Base) ​

AstrBot supports custom endpoint via api_base_url for environments without stable public IP.

Voice Input ​

Install ffmpeg for voice input support.

  • Linux: apt install ffmpeg
  • Windows: download from FFmpeg website
  • macOS: brew install ffmpeg
Edit this page on GitHub

Last updated:

Pager
PreviousWeCom AI Bot
NextLark

Deployed on Rainyun Logo