Gasoline implements the Model Context Protocol — a standard for connecting AI assistants to external tools. Any MCP-compatible tool can tap into your browser state.
Supported Tools
| Tool | Config Location | Guide |
|---|---|---|
| Claude Code | .mcp.json (project root) |
Setup → |
| Cursor | ~/.cursor/mcp.json |
Setup → |
| Windsurf | ~/.codeium/windsurf/mcp_config.json |
Setup → |
| Claude Desktop | OS-specific config file | Setup → |
| Zed | ~/.config/zed/settings.json |
Setup → |
| VS Code + Continue | ~/.continue/config.json |
Below |
How MCP Mode Works
With --mcp, Gasoline runs as a dual-mode server:
- HTTP server — background process for the browser extension
- MCP protocol — stdio channel for your AI tool
- Auto-managed — your AI tool starts and stops the server
Available MCP Tools
Once the pipeline is connected:
| Tool | Description |
|---|---|
get_browser_errors |
Console errors, network failures, exceptions |
get_browser_logs |
All logs (errors, warnings, info) |
clear_browser_logs |
Clear the log file |
get_websocket_events |
WebSocket events. Filter by URL, ID, direction |
get_websocket_status |
Connection states, rates, schemas |
get_network_bodies |
Request/response bodies. Filter by URL, method, status |
query_dom |
Live DOM query with CSS selectors |
get_page_info |
Page URL, title, viewport |
run_accessibility_audit |
Accessibility violations |
Custom Port
If port 7890 is occupied:
{
"mcpServers": {
"gasoline": {
"command": "npx",
"args": ["gasoline-mcp", "--mcp", "--port", "7891"]
}
}
}
Update the extension’s Server URL in Options to match.
VS Code with Continue
Add to ~/.continue/config.json:
{
"experimental": {
"modelContextProtocolServers": [
{
"transport": {
"type": "stdio",
"command": "npx",
"args": ["gasoline-mcp", "--mcp"]
}
}
]
}
}
Verify the Connection
- Restart your AI tool
- Gasoline server ignites automatically
- Extension popup shows “Connected”
- Ask your AI: “What browser errors do you see?”