English | 简体中文
Runtime eyes for AI agents.
Peekit is an AI-first runtime inspection MCP server. It gives coding agents measured evidence from H5 and Weixin Mini Program targets: page state, element text, DOM markup or WXML, rects, computed styles, console output, errors, interactions, before/after snapshots, and diagnosis hints.
Peekit is not designed as a human-operated CLI workflow. The npm package is the distribution vehicle for the MCP server.
Add Peekit to an MCP client:
{
"mcpServers": {
"peekit": {
"command": "npx",
"args": ["-y", "@peekit/cli", "mcp"]
}
}
}Then ask your coding agent natural-language UI questions:
Check why this button does not show a loading state after click.Compare the measured spacing, color, and visibility of this page between H5 and Weixin mini program.After the fix, verify with Peekit using before/after runtime evidence.For local runtime paths, use ~/.peekit/local-setup.json for machine-wide paths and <repo>/.peekit/local-setup.json for project overrides. Weixin targets require weixin.automation.servicePortEnabled: true after the Developer Tools service port is enabled in security settings.
Peekit exposes these MCP tools:
peekit_inspect_environmentpeekit_suggest_target_configpeekit_suggest_mcp_client_configpeekit_validate_targetpeekit_explain_setup_blockerpeekit_list_targetspeekit_connect_targetpeekit_get_current_pagepeekit_open_pagepeekit_query_elementpeekit_query_allpeekit_capture_snapshotpeekit_perform_interactionpeekit_compare_snapshotspeekit_diagnose_issuepeekit_suggest_next_probepeekit_record_casepeekit_replay_casepeekit_cross_target_compare
| Target | Status | Notes |
|---|---|---|
| H5 | Implemented | Playwright-backed page, DOM, text, rect, computed style, console, errors, click, tap, input, scroll, hover |
| Weixin mini program | Implemented | Uses miniprogram-automator to connect Weixin Developer Tools and capture route, WXML, text, size, offset, style, console, errors, tap, input, and scroll |
| Alipay mini program | Roadmap | Not part of the alpha support scope; returns explicit unsupported evidence |
| ByteDance mini program | Roadmap | Not part of the alpha support scope; returns explicit unsupported evidence |
| QQ mini program | Roadmap | Not part of the alpha support scope; returns explicit unsupported evidence |
Unsupported fields are reported explicitly so agents can reason from capability evidence instead of guessing.
pnpm install
pnpm build
pnpm testPackage layout:
packages/
core/
mcp-server/
adapter-h5/
adapter-mp-weixin/
adapter-mp-alipay/
adapter-mp-bytedance/
adapter-mp-qq/
reporter/
docs/
examples/See docs/ai-usage.md and docs/agent-contract.md for the agent workflow and runtime evidence contract.
For real Weixin Developer Tools setup, see docs/weixin-troubleshooting.md.
For alpha publishing, see docs/release.md.