WebSee MCP Server
Provides AI assistants with advanced frontend debugging capabilities through 36 specialized tools for inspecting React/Vue/Angular/Svelte applications. Uses Playwright browser automation and source map intelligence to analyze components, network requests, bundle optimization, and resolve production errors.
README
WebSee MCP Server
Advanced frontend debugging intelligence for AI assistants via the Model Context Protocol (MCP).
Overview
WebSee is a production-ready MCP server that provides AI assistants with powerful frontend debugging capabilities through 36 specialized tools organized into 6 modular skills. It uses Playwright for browser automation combined with source map intelligence to provide deep insights into React, Vue, Angular, and Svelte applications.
Key Features
- 36 Specialized Tools - Component inspection, network analysis, source maps, build intelligence, error resolution
- 6 Modular Skills - Progressive disclosure from high-level workflows to granular operations
- Framework Support - React (full), Vue (good), Angular (moderate), Svelte (basic)
- Source Map Intelligence - Resolve minified code to original source with Webpack, Vite, Rollup support
- Browser Automation - Powered by Playwright with Chromium, Firefox, or WebKit
- Production Ready - 100% test coverage, 1.6s average response time
Quick Start
Installation
npm install websee-mcp-server
Configuration
Claude Code
Create .mcp.json in your project root:
{
"mcpServers": {
"websee": {
"command": "node",
"args": ["node_modules/websee-mcp-server/dist/mcp-server.js"],
"env": {
"BROWSER": "chromium",
"HEADLESS": "true"
}
}
}
}
VS Code
Create .vscode/mcp.json:
{
"servers": {
"websee": {
"command": "node",
"args": ["${workspaceFolder}/node_modules/websee-mcp-server/dist/mcp-server.js"],
"env": {
"BROWSER": "chromium",
"HEADLESS": "true"
}
}
}
}
Cursor
Create .cursor/mcp.json:
{
"mcpServers": {
"websee": {
"command": "node",
"args": ["./node_modules/websee-mcp-server/dist/mcp-server.js"],
"env": {
"BROWSER": "chromium",
"HEADLESS": "true"
}
}
}
}
Usage
Once configured, AI assistants can use WebSee tools directly:
Use debug_frontend_issue to investigate https://example.com
Focus on the login form
Capture a screenshot
Available Skills
Workflow Layer (6 tools)
High-level tools for comprehensive analysis:
- debug_frontend_issue - Multi-faceted debugging (console, components, network, errors)
- analyze_performance - Performance analysis across all dimensions
- inspect_component_state - Component state and props inspection
- trace_network_requests - Network request tracing with source code
- analyze_bundle_size - JavaScript bundle analysis and optimization
- resolve_minified_error - Error resolution with source maps
Granular Layer (30 tools)
Specialized tools organized by category:
Component Intelligence (8 tools)
- component_tree, component_get_props, component_get_state, component_find_by_name
- component_get_source, component_track_renders, component_get_context, component_get_hooks
Network Intelligence (6 tools)
- network_get_requests, network_get_by_url, network_get_timing
- network_trace_initiator, network_get_headers, network_get_body
Source Intelligence (7 tools)
- source_map_resolve, source_map_get_content, source_trace_stack
- source_find_definition, source_get_symbols, source_map_bundle, source_coverage_map
Build Intelligence (5 tools)
- build_get_manifest, build_get_chunks, build_find_module
- build_get_dependencies, build_analyze_size
Error Intelligence (4 tools)
- error_resolve_stack, error_get_context, error_trace_cause, error_get_similar
Skills Documentation
Comprehensive skill guides available in skills/ directory:
- Frontend Debugger - Workflow tools
- Component Intelligence - Component debugging
- Network Intelligence - Network analysis
- Source Intelligence - Source map navigation
- Build Intelligence - Bundle optimization
- Error Intelligence - Error resolution
Prerequisites
Required
- Node.js 16+ and npm
- One of: Chromium, Firefox, or WebKit (installed automatically with Playwright)
Optional (Enhanced Functionality)
- React DevTools - For component intelligence (6/8 tools)
- Source Maps - For source intelligence (all 7 tools)
- Build Artifacts - For build intelligence (stats.json or manifest.json)
Common Use Cases
Debug Production Error
1. error_resolve_stack → Get enhanced stack trace
2. source_map_resolve → Navigate to original code
3. component_get_state → Check component state
4. Fix the issue
Optimize Performance
1. analyze_performance → Identify bottlenecks
2. network_get_timing → Find slow requests
3. build_analyze_size → Optimize bundle size
4. component_track_renders → Reduce re-renders
Component Debugging
1. component_tree → Understand hierarchy
2. component_get_props → Verify inputs
3. component_get_state → Check internal state
4. network_get_requests → See API calls
Bundle Analysis
1. build_analyze_size → Get size breakdown
2. build_get_chunks → Analyze chunks
3. build_get_dependencies → Find duplicates
4. Implement code splitting
Framework Support
| Framework | Component Tools | Success Rate | DevTools Required |
|---|---|---|---|
| React | 8/8 (100%) | 100% | Yes (6/8 tools) |
| Vue | 6/8 (75%) | 90% | Yes |
| Angular | 5/8 (63%) | 70% | Yes |
| Svelte | 4/8 (50%) | 50% | Optional |
Build Tool Support
| Build Tool | Source Maps | Build Artifacts | Support Level |
|---|---|---|---|
| Webpack 4/5 | ✅ Full | stats.json | ✅ Full |
| Vite 2/3/4 | ✅ Full | manifest.json | ✅ Full |
| Rollup | ✅ Good | Partial | ⚠️ Partial |
| esbuild | ✅ Partial | No | ⚠️ Partial |
| Parcel | ✅ Partial | Partial | ⚠️ Partial |
Performance
Based on comprehensive testing with 100+ test cases:
- Average Response Time: 1.6s
- Test Pass Rate: 100%
- Tool Coverage: 36/36 tools
- Production Ready: ✅ Yes
| Tool Category | Response Time | Success Rate |
|---|---|---|
| Workflow | 2.0s | 100% |
| Component | 1.2s | 100%* |
| Network | 2.6s | 100% |
| Source | 1.5s | 100%* |
| Build | 1.3s | 100%* |
| Error | 1.1s | 100% |
* With prerequisites (DevTools, source maps, build artifacts)
Environment Variables
Configure via .env file or environment:
# Browser Selection
BROWSER=chromium # chromium, firefox, or webkit
# Headless Mode
HEADLESS=true # true for headless, false for headed
# Project Root
PROJECT_ROOT=. # Path to project root
Compatibility
✅ Claude Code - Full support ✅ VS Code - Full support via MCP extension ✅ Cursor - Full support (36 tools < 40 tool limit)
Architecture
WebSee MCP Server
├── Workflow Layer (6 tools)
│ └── High-level, multi-faceted analysis
├── Granular Layer (30 tools)
│ ├── Component Intelligence (8 tools)
│ ├── Network Intelligence (6 tools)
│ ├── Source Intelligence (7 tools)
│ ├── Build Intelligence (5 tools)
│ └── Error Intelligence (4 tools)
└── Core Services
├── BrowserManager (Playwright)
├── SourceMapResolver
├── ComponentTracker
├── NetworkTracer
└── BuildArtifactManager
Development
Build from Source
# Clone repository
git clone https://github.com/1aq/websee-mcp-server.git
cd websee-mcp-server
# Install dependencies
npm install
# Build
npm run build
# Test
npm test
Project Structure
websee-mcp-server/
├── src/ # TypeScript source code
│ ├── mcp-server.ts # Main MCP server
│ ├── browser-manager.ts # Playwright wrapper
│ ├── source-map-resolver.ts
│ ├── component-tracker.ts
│ ├── network-tracer.ts
│ ├── build-artifact-manager.ts
│ └── tools/ # Tool implementations
├── skills/ # Skill documentation
├── dist/ # Compiled JavaScript
├── package.json
├── tsconfig.json
└── README.md
Troubleshooting
"Browser not found"
Install Playwright browsers:
npx playwright install chromium
"DevTools required"
Install framework DevTools:
"Source maps not available"
Enable source maps in your build:
Webpack:
module.exports = {
devtool: 'source-map'
};
Vite:
export default {
build: { sourcemap: true }
};
"Component not found"
- Verify selector matches actual DOM element
- Wait for component to mount
- Use
component_find_by_nameto locate component - Check if element is a framework component (not plain HTML)
Security Considerations
Production Deployment
- Source Maps: Use
hidden-source-mapin Webpack to prevent public access - DevTools: Only enable for debugging, not for all users
- Environment Variables: Never commit sensitive data to
.env - CORS: Configure properly for cross-origin requests
Best Practices
- Run in headless mode in CI/CD pipelines
- Use specific selectors to avoid unintended matches
- Enable source maps only in staging/development
- Review component state for sensitive data before logging
Contributing
We welcome contributions! Please see our contributing guidelines.
License
MIT License - see LICENSE file for details.
Support
- GitHub Issues: github.com/1AQuantum/websee-mcp-server/issues
- Documentation: See
skills/directory for detailed guides - Examples: See skill documentation for real-world examples
Acknowledgments
Built with:
- Playwright - Browser automation
- Model Context Protocol - AI tool protocol
- Anthropic - MCP specification and guidelines
Version: 1.0.0 Status: ✅ Production Ready Test Coverage: 100% Tools: 36 Skills: 6
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。