Skip to content

Commit 34f0326

Browse files
authored
Update README.md
1 parent d4227c9 commit 34f0326

File tree

1 file changed

+42
-101
lines changed

1 file changed

+42
-101
lines changed

README.md

Lines changed: 42 additions & 101 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Hyperbrowser MCP Server
22

3-
This project is a server implementation for the Hyperbrowser using the Model Context Protocol (MCP). The server provides various tools to scrape, extract structured data, and crawl webpages.
3+
This project is a server implementation for the Hyperbrowser using the Model Context Protocol (MCP). The server provides various tools to scrape, extract structured data, and crawl webpages. It also provides easy access to general purpose browser agents like OpenAI's CUA, Anthropic's Claude Computer Use, and Browser Use.
44

55
More information about the Hyperbrowser can be found [here](https://docs.hyperbrowser.ai/). The hyperbrowser API supports a superset of features present in the mcp server.
66

@@ -10,11 +10,7 @@ More information about the Model Context Protocol can be found [here](https://mo
1010

1111
- [Installation](#installation)
1212
- [Usage](#usage)
13-
- [Example config](#example-config)
1413
- [Tools](#tools)
15-
- [Scrape Webpage](#scrape-webpage)
16-
- [Extract Structured Data](#extract-structured-data)
17-
- [Crawl Webpages](#crawl-webpages)
1814
- [Configuration](#configuration)
1915
- [License](#license)
2016

@@ -23,7 +19,39 @@ More information about the Model Context Protocol can be found [here](https://mo
2319
To install the server, run:
2420

2521
```bash
26-
npx hyperbrowser-mcp
22+
npx hyperbrowser-mcp <YOUR-HYPERBROWSER-API-KEY>
23+
```
24+
25+
## Running on Cursor
26+
Add to `~/.cursor/mcp.json` like this:
27+
```json
28+
{
29+
"mcpServers": {
30+
"hyperbrowser": {
31+
"command": "npx",
32+
"args": ["-y", "hyperbrowser-mcp"],
33+
"env": {
34+
"HYPERBROWSER_API_KEY": "YOUR-API-KEY"
35+
}
36+
}
37+
}
38+
}
39+
```
40+
41+
## Running on Windsurf
42+
Add to your `./codeium/windsurf/model_config.json` like this:
43+
```json
44+
{
45+
"mcpServers": {
46+
"hyperbrowser": {
47+
"command": "npx",
48+
"args": ["-y", "hyperbrowser-mcp"],
49+
"env": {
50+
"HYPERBROWSER_API_KEY": "YOUR-API-KEY"
51+
}
52+
}
53+
}
54+
}
2755
```
2856

2957
### Development
@@ -50,8 +78,7 @@ For development purposes, you can run the server directly from the source code.
5078
node dist/server.js
5179
```
5280

53-
### Example config
54-
81+
## Claude Desktop app
5582
This is an example config for the Hyperbrowser MCP server for the Claude Desktop client.
5683

5784
```json
@@ -68,107 +95,21 @@ This is an example config for the Hyperbrowser MCP server for the Claude Desktop
6895
}
6996
```
7097

71-
Other client (such as Cursor) do not support the `env` field in the config or as a part of the command param. In that case, you can use a shell script to run the server with the correct environment variable. An example shell script is provided in the repository as `run_server.sh`.
72-
73-
```json
74-
{
75-
"mcpServers": {
76-
"hyperbrowser": {
77-
"command": "bash",
78-
"args": ["/path/to/hyperbrowser-mcp/run_server.sh"]
79-
}
80-
}
81-
}
82-
```
83-
84-
### Running with SSE
85-
86-
The server can also be run in Server-Sent Events (SSE) mode, which allows for real-time communication over HTTP. To run the server in SSE mode, use the `--sse` flag:
87-
88-
```bash
89-
npx --yes hyperbrowser-mcp --sse
90-
```
91-
92-
## Specifying the port for SSE
93-
94-
By default, the SSE server will start on port 3001. The port can be customized using the `SSE_PORT` env var.
95-
96-
```bash
97-
SSE_PORT=3010 npx --yes hyperbrowser-mcp --sse
98-
```
99-
100-
If for some reason you can't provide the API key in the config or in a shell script, you can set it within whatever prompt you are using. It will be upto the mcp client to pass it to the server.
10198

10299
## Tools
100+
* `scrape_webpage` - Extract formatted (markdown, screenshot etc) content from any webpage
101+
* `crawl_webpages` - Navigate through multiple linked pages and extract LLM-friendly formatted content
102+
* `extract_structured_data` - Convert messy HTML into structured JSON
103+
* `search_with_bing` - Query the web and get results with Bing search
104+
* `browser_use_agent` - Fast, lightweight browser automation with the Browser Use agent
105+
* `openai_computer_use_agent` - General-purpose automation using OpenAI’s CUA model
106+
* `claude_computer_use_agent` - Complex browser tasks using Claude computer use
103107

104-
### Scrape Webpage
105-
106-
This tool allows you to scrape a webpage and retrieve content in various formats such as markdown, HTML, links, and screenshots.
107-
108-
#### Parameters:
109-
110-
- `url`: The URL of the webpage to scrape.
111-
- `apiKey`: (Optional) The API key to use for browser control. If not provided, then will look for the API Key in the environment variables.
112-
- `sessionOptions`: (Optional) Options for the browser session.
113-
- `outputFormat`: The format of the output (from a list of markdown, html, links, screenshot).
114-
115-
### Extract Structured Data
116-
117-
This tool extracts structured information from a list of webpages using a specified prompt and JSON schema.
118-
119-
#### Parameters:
120-
121-
- `urls`: The list of URLs of the webpages to extract structured information from.
122-
- `apiKey`: (Optional) The API key to use for browser control. If not provided, then will look for the API Key in the environment variables.
123-
- `sessionOptions`: (Optional) Options for the browser session.
124-
- `prompt`: (Optional - if not provided, the tool will try to infer the prompt from the schema) The prompt to use for the extraction.
125-
- `schema`: (Optional - if not provided, the tool will try to infer the schema from the prompt) The JSON schema to use for the extraction.
126-
127-
### Crawl Webpages
128-
129-
This tool crawls a list of webpages, optionally following links and limiting the number of pages.
130-
131-
#### Parameters:
132-
133-
- `url`: The URL of the webpage to crawl.
134-
- `apiKey`: (Optional) The API key to use for browser control. If not provided, then will look for the API Key in the environment variables.
135-
- `sessionOptions`: (Optional) Options for the browser session.
136-
- `outputFormat`: The format of the output (from a list of markdown, html, links, screenshot).
137-
- `followLinks`: Whether to follow links on the crawled webpages.
138-
- `maxPages`: The maximum number of pages to crawl.
139-
140-
### Browser Use
141-
142-
This tool creates a Browser Use session, and uses taht to accomplish the task provided.
143-
**Note: This can be a very long running process depending on the task, so make sure that the timeout is configured accordingly.**
144-
145-
#### Parameters:
146-
147-
- `task`: The task to accomplish using Browser Use.
148-
- `apiKey`: (Optional) The API key to use for browser control. If not provided, then will look for the API Key in the environment variables.
149-
- `sessionOptions`: (Optional) Options for the browser session.
150-
- `returnStepInfo`: (Optional) Returns the information about the intermediate steps taked. **Note that this is a large amount of information and can fill up the context window very quickly. We recommend setting this to `false`**.
151-
- `maxSteps`: (Optional) The maximum number of steps to perform while doing the task.
152-
153-
### Session Options
154-
155-
The `sessionOptions` parameter allows you to configure various aspects of the browser session. It is an optional parameter and can include the following fields:
156-
157-
- `useProxy`: (Optional) Whether to use a proxy.
158-
- `useStealth`: (Optional) Whether to use stealth mode.
159-
- `solveCaptchas`: (Optional) Whether to solve captchas.
160-
- `acceptCookies`: (Optional) Whether to automatically close the accept cookies popup.
161-
162-
These options help in customizing the behavior of the browser session to suit your specific needs.
163108

164109
## Resources
165110

166111
The server provides the documentation about hyperbrowser through the `resources` methods. Any client which can do discovery over resources has access to it.
167112

168-
## Configuration
169-
170-
The server can be configured using environment variables or by modifying the source code directly. Ensure that the `HYPERBROWSER_API_KEY` environment variable is set if you are not providing an API key directly in the requests.
171-
172113
## License
173114

174115
This project is licensed under the MIT License.

0 commit comments

Comments
 (0)