Browser Automation MCP Server
This is a Model Context Protocol (MCP) server that provides browser automation capabilities for Roo Code. It enables AI agents to control web browsers through a standardized interface.
Features
- Browser control (launch, close)
- Mouse interactions (click at coordinates)
- Keyboard input (type text)
- Page navigation (scroll up/down)
- Fixed viewport size (900x600)
Installation
- Clone the repository:
git clone https://github.com/grapheneaffiliates/browser-automation-mcp.git
cd browser-automation-mcp
- Install dependencies:
- Build the project:
Configuration
Add the following to your Cline MCP settings file:
{
"mcpServers": {
"browser": {
"command": "node",
"args": ["path/to/browser-server/build/index.js"],
"disabled": false,
"alwaysAllow": []
}
}
}
The server provides the following MCP tools:
launch_browser
: Launch a new browser instance at a specified URLclick
: Click at specific x,y coordinates on the pagetype
: Type text into the pagescroll
: Scroll the page up or downclose_browser
: Close the browser instance
Usage Example
// Using the MCP tools in Roo Code
const result = await use_mcp_tool({
server_name: "browser",
tool_name: "launch_browser",
arguments: {
url: "https://example.com"
}
});
License
MIT