wechat-cli-local-data

Query local WeChat chat history, contacts, and sessions with JSON output.

4|Updated May 16, 2026
One-click install
npx skills add https://github.com/reason-machines/devtools-skills --skill wechat-cli-local-data-reason-machines
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: wechat-cli-local-data
Source: https://github.com/reason-machines/devtools-skills/tree/main/skills/wechat-cli-local-data
Command: npx skills add https://github.com/reason-machines/devtools-skills --skill wechat-cli-local-data-reason-machines

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Accessing your own WeChat chat history, contacts, and favorites normally requires manual scrolling through the app, with no way to search, export, or analyze conversations programmatically. This Skill lets an AI agent query locally stored WeChat data from the command line and return structured JSON results. ## Core Features & Use Cases - Chat History & Search: Read message history, search across one or multiple chats, and filter by date range or message type (text, image, file, link, etc.). - Contacts, Groups & Stats: Look up contact details, list group members, and generate chat analytics such as message counts, top senders, and activity distribution. - Export & Monitoring: Export conversations to Markdown or TXT, list unread sessions, and track new messages incrementally for cron-based monitoring. - Use Case: Ask your agent to find every message mentioning "deadline" across three project groups from last month, then export the relevant conversation to a Markdown file for a weekly report. ## Quick Start Ask the agent to run wechat-cli sessions to list your recent WeChat chats, then use wechat-cli history with a chat name to read recent messages.

Frequently Asked Questions about wechat-cli-local-data

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I search my WeChat chat history from the command line?▼

Use wechat-cli search with a keyword, optionally scoped to specific chats with --chat, filtered by date range or message type. Results return as JSON by default, or add --format text for readable output.

How to export WeChat conversations to Markdown?▼

Run wechat-cli export with the chat name, --format markdown, and --output for the target file. You can limit the export with --start-time, --end-time, and --limit to capture a specific period.

Does wechat-cli work on Windows and Linux?▼

Yes, wechat-cli supports macOS, Windows, and Linux. The npm package ships a macOS arm64 binary, while other platforms install via pip with Python 3.10 or later. Windows reads Weixin.exe process memory and Linux reads /proc/pid/mem.

Why does wechat-cli init fail with task_for_pid failed on macOS?▼

This error occurs because macOS blocks memory scanning of the WeChat process. The tool can automatically re-sign WeChat with the get-task-allow entitlement; quit and reopen WeChat, then run sudo wechat-cli init again.

Does wechat-cli send my chat data to the cloud?▼

No, all data stays on your machine. The tool performs local SQLCipher decryption and SQLite queries with no network access, and it is read-only, so it never sends or modifies messages.

Why does wechat-cli return empty results for a valid chat name?▼

Chat names are case-sensitive and must match exactly, including full group names as shown in WeChat. Run wechat-cli sessions to see exact names, or use contacts --query for partial name matching.