Web Agent Protocol
🌐Web Agent Protocol (WAP) - Record and replay user interactions in the browser with MCP support
What is Web Agent Protocol?
Web Agent Protocol is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to 🌐web agent protocol (wap) - record and replay user interactions in the browser with mcp support
🌐Web Agent Protocol (WAP) - Record and replay user interactions in the browser with MCP support
This server falls under the Browser Automation category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- 🌐Web Agent Protocol (WAP) - Record and replay user interacti
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx web-agent-protocolConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Web Agent Protocol
Web Agent Protocol (WAP) is a standardized browser automation framework that lets you record real user interactions in Chrome via a browser extension, then convert those recordings into exact-replay or smart-replay action lists, and finally package them as MCP servers that any AI agent can call. The workflow separates recording from execution: a human performs an action once, WAP captures the full DOM context, and the resulting MCP server lets Claude or any other agent replay that workflow reliably. Developers use it to capture complex authenticated workflows that are too brittle for pure AI navigation and expose them as reusable agent tools.
Prerequisites
- Python 3.11 (create a conda env or use a virtualenv)
- conda or venv for environment isolation
- The OTA-WAP Chrome extension installed in Chrome for recording sessions
- An OpenAI API key (OPENAI_API_KEY) or DeepSeek API key (DEEPSEEK_API_KEY) for smart replay generation
- Playwright installed in the Python environment for replay execution
Set up the Python environment
Create and activate a conda environment with Python 3.11, then install the project dependencies.
conda create -n WAP python=3.11
conda activate WAP
pip install -r requirements.txtSet environment variables and PYTHONPATH
Create a .env file with your LLM API key and export the repo root as PYTHONPATH so all modules resolve correctly.
# Create .env file:
# OPENAI_API_KEY=sk-proj-...
# DEEPSEEK_API_KEY=sk-...
# Set PYTHONPATH (Linux/macOS):
export PYTHONPATH=/path/to/webagentprotocol
# Windows:
# set PYTHONPATH=C:/path/to/webagentprotocolRecord a browser session
Start the data collection server, then use the OTA-WAP Chrome extension to record your workflow. Each session is saved as a JSON file under data/YYYYMMDD/<taskid>/.
python action_collect_server.py
# The server listens on http://localhost:4934/action-data
# Start recording from Chrome using the WAP extensionGenerate a replay list from the recording
Convert the raw recording into a smart replay list (goal-oriented, condensed steps) or an exact replay list (reproduces every action verbatim).
# Smart replay (recommended for agents)
python wap_replay/generate_smart_replay_list.py \
--data_dir_path data/<YYYYMMDD>/<task_id> \
--output_dir_path data_processed/smart_replay
# Exact replay
python wap_replay/generate_exact_replay_list.py \
--data_dir_path data/<YYYYMMDD>/<task_id> \
--output_dir_path data_processed/exact_replayConvert the replay list to an MCP server
Generate an MCP server from your recorded task. The server will be placed in the mcp_servers/ folder and can be added to any MCP client.
python wap_replay/generate_mcp_server.py --task_id <task_id>Run the MCP service and connect a client
Start the WAP service in one terminal and the MCP client in another. You can then send natural language prompts to replay your recorded workflows.
# Terminal 1:
python wap_service.py
# Terminal 2:
python mcp_client.py
# Then enter a prompt like:
# find a top rated keyboard on amazon.ca using smart replayWeb Agent Protocol Examples
Client configuration
Example MCP server configuration for a generated WAP MCP server. The actual command depends on the generated server in mcp_servers/<task_id>/.
{
"mcpServers": {
"wap-workflow": {
"command": "python",
"args": ["mcp_servers/<task_id>/server.py"],
"cwd": "/path/to/webagentprotocol",
"env": {
"OPENAI_API_KEY": "sk-proj-your-key-here",
"PYTHONPATH": "/path/to/webagentprotocol"
}
}
}
}Prompts to try
After converting a recorded workflow to an MCP server, use these types of prompts to replay it.
- "Find a top rated mechanical keyboard on amazon.ca using smart replay"
- "Run the recorded checkout workflow for the item in my cart"
- "Use the saved login workflow to authenticate and navigate to my dashboard"
- "Replay the data export workflow and save the results to a file"Troubleshooting Web Agent Protocol
ModuleNotFoundError when running WAP scripts
Run all commands from the project root directory with PYTHONPATH set to the repo root. On Linux/macOS: 'export PYTHONPATH=.' or 'export PYTHONPATH=/path/to/webagentprotocol'. On Windows: 'set PYTHONPATH=.'.
generate_smart_replay_list.py fails with 'no task-start file' error
The generators require exactly one task-start and one task-finish event record in the session data. Ensure the Chrome extension recorded a complete session — start the recording before the first action and stop it after the final action on the page.
Replay fails midway through a workflow due to DOM changes or dynamic content
Use smart replay mode instead of exact replay. Smart replay generates goal-oriented steps that are more resilient to minor DOM changes. If failures persist, re-record the specific failing segment and regenerate the replay list.
Frequently Asked Questions about Web Agent Protocol
What is Web Agent Protocol?
Web Agent Protocol is a Model Context Protocol (MCP) server that 🌐web agent protocol (wap) - record and replay user interactions in the browser with mcp support It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Web Agent Protocol?
Follow the installation instructions on the Web Agent Protocol GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Web Agent Protocol?
Web Agent Protocol works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Web Agent Protocol free to use?
Yes, Web Agent Protocol is open source and available under the MIT license. You can use it freely in both personal and commercial projects.
Web Agent Protocol Alternatives — Similar Browser Automation Servers
Looking for alternatives to Web Agent Protocol? Here are other popular browser automation servers you can use with Claude, Cursor, and VS Code.
Chrome DevTools MCP
★ 40.6kAI-powered Chrome automation server with natural language element detection. Control Chrome browser through MCP protocol for testing, debugging, and performance analysis. Features 91% accuracy in element location, works with free AI models, and suppo
UI TARS Desktop
★ 34.9k📇 🏠 - Browser automation capabilities using Puppeteer, both support local and remote browser connection.
Playwright
★ 32.8kA production-ready browser automation server that enables AI assistants to interact with web pages using tools for navigation, element interaction, and data extraction. It features a built-in Inspector UI and robust crash recovery for reliable automa
Page Agent
★ 18.0kJavaScript in-page GUI agent. Control web interfaces with natural language.
Chrome
★ 11.7kAn extension-based MCP server that enables AI assistants to control your browser, leveraging existing sessions and login states for automation and content analysis. It provides over 20 tools for semantic tab search, interactive element manipulation,
LAMDA
★ 7.8kThe most powerful Android RPA agent framework, next generation mobile automation.
Browse More Browser Automation MCP Servers
Explore all browser automation servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Web Agent Protocol in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Web Agent Protocol?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.