@browserstack/mcp-server 1.0.1 โ 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +116 -64
- package/dist/tools/sdk-utils/constants.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,61 +1,35 @@
|
|
|
1
1
|
# BrowserStack MCP Server
|
|
2
|
-
|
|
2
|
+
|
|
3
|
+
<div align="center">
|
|
3
4
|
<img src="assets/browserstack-logo.png" alt="BrowserStack Logo" height="100"> <img src="assets/mcp-logo.png" alt="MCP Server Logo" width="100">
|
|
4
5
|
</div>
|
|
5
6
|
|
|
7
|
+
<div align="center">
|
|
8
|
+
<a href="https://www.npmjs.com/package/@browserstack/mcp-server">
|
|
9
|
+
<img alt="NPM Version" src="https://img.shields.io/npm/v/%40browserstack%2Fmcp-server">
|
|
10
|
+
</a>
|
|
6
11
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
[](https://www.youtube.com/watch?v=vy1sx0J7sTk)
|
|
12
|
+
</div>
|
|
10
13
|
|
|
11
|
-
## ๐ Overview
|
|
12
|
-
BrowserStack MCP Server brings the power of BrowserStack's [Test Platform](https://www.browserstack.com/test-platform) directly into your development workflow. It enables you to run tests, debug applications, and perform cross-browser testing through any [MCP-compliant client](https://modelcontextprotocol.io/clients#feature-support-matrix).
|
|
13
14
|
|
|
14
|
-
|
|
15
|
+
<h3 align="center">One Platform For All Your Testing Needs</h4>
|
|
15
16
|
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
- **Live Debugging**: Debug crashes and performance issues in real-time
|
|
20
|
-
- **Comprehensive Device Coverage**: Access all major devices and OS versions from our [device grid](https://www.browserstack.com/list-of-browsers-and-platforms/app_live)
|
|
17
|
+
## ๐ Overview
|
|
18
|
+
Enable every developer and tester in your team, whether they are testing manually, starting their automation journey, or scaling test automation.
|
|
19
|
+
BrowserStack MCP Server allows you to use our cutting-edge [Test Platform](https://www.browserstack.com/test-platform) directly from your favourite AI tools.
|
|
21
20
|
|
|
22
|
-
###
|
|
23
|
-
- **Local Testing**: Seamlessly test websites hosted on localhost
|
|
24
|
-
- **Cross-Browser Testing**: Test websites across different browsers and devices
|
|
25
|
-
- **Screenshot Testing**: Capture and compare screenshots across different environments
|
|
21
|
+
### Why BrowserStack ?
|
|
26
22
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
- **Accessibility Testing**: Ensure WCAG and ADA compliance with our [Accessibility Testing](https://www.browserstack.com/accessibility-testing) tool
|
|
23
|
+
<p align="center">
|
|
24
|
+
<img src="assets/overview.png" alt="overview">
|
|
25
|
+
</p>
|
|
31
26
|
|
|
32
|
-
##
|
|
27
|
+
## ๐ก Usage Examples
|
|
33
28
|
|
|
34
|
-
|
|
35
|
-
- Sign up at [BrowserStack](https://www.browserstack.com/signup)
|
|
36
|
-
- Get your credentials from [Account Settings](https://www.browserstack.com/accounts/profile/details)
|
|
29
|
+
### ๐ฑ Manual App Testing
|
|
37
30
|
|
|
38
|
-
|
|
39
|
-
- Sample MCP Server config for Cursor: `.cursor/mcp.json`:
|
|
40
|
-
```json
|
|
41
|
-
{
|
|
42
|
-
"mcpServers": {
|
|
43
|
-
"browserstack_mcp_server": {
|
|
44
|
-
"command": "npx",
|
|
45
|
-
"args": ["@browserstack/mcp-server"],
|
|
46
|
-
"env": {
|
|
47
|
-
"BROWSERSTACK_USERNAME": "<username>",
|
|
48
|
-
"BROWSERSTACK_ACCESS_KEY": "<access_key>"
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
```
|
|
54
|
-
- For Github Copilot users, ensure you are using the latest version of the VSCode with support for Copilot agent mode.
|
|
31
|
+
Use the following prompts to use your **mobile apps** on BrowserStack's extensive cloud of real devices. Stop using emulators!
|
|
55
32
|
|
|
56
|
-
## ๐ก Usage Examples
|
|
57
|
-
|
|
58
|
-
### App Testing
|
|
59
33
|
```bash
|
|
60
34
|
# Open app on specific device
|
|
61
35
|
"open my app on a iPhone 15 Pro Max"
|
|
@@ -64,19 +38,32 @@ BrowserStack MCP Server brings the power of BrowserStack's [Test Platform](https
|
|
|
64
38
|
"My app crashed on Android 14 device, can you help me debug?"
|
|
65
39
|
```
|
|
66
40
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
41
|
+
Video Walkthrough:
|
|
42
|
+
|
|
43
|
+
[](https://www.youtube.com/watch?v=vy1sx0J7sTk)
|
|
44
|
+
|
|
45
|
+
- Unlike emulators, test your app's real-world performance on actual devices. With advanced [App-Profiling features](https://www.browserstack.com/docs/app-live/app-performance-testing), you can debug crashes and performance issues in real-time.
|
|
46
|
+
- Access all major devices and OS versions from our [device grid](https://www.browserstack.com/list-of-browsers-and-platforms/app_live), We have strict SLAs to provision our global datacenters with newly released devices on [launch day](https://www.browserstack.com/blog/browserstack-launches-iphone-15-on-day-0-behind-the-scenes/).
|
|
47
|
+
|
|
48
|
+
### ๐ Manual Web Testing
|
|
71
49
|
|
|
72
|
-
|
|
73
|
-
|
|
50
|
+
Similar to the app testing, you can use the following prompts to test your **websites** on BrowserStack's extensive cloud of real browsers and devices. Don't have a Windows machine to test on Internet Explorer? We've got you covered!
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
# Test your local websites
|
|
54
|
+
"open my website hosted on localhost:3001 on Internet Explorer"
|
|
74
55
|
```
|
|
75
56
|
|
|
76
|
-
|
|
57
|
+
- Test websites across different browsers and devices. We support [every major browser](https://www.browserstack.com/list-of-browsers-and-platforms/live) across every major OS.
|
|
58
|
+
- Seamlessly test websites hosted locally on your machine, no need to deploy to a remote server!
|
|
59
|
+
|
|
60
|
+
### ๐งช Automated Testing (Playwright, Selenium, A11y and more..)
|
|
61
|
+
|
|
62
|
+
Use the following prompts to run/debug/fix your **automated tests** on BrowserStack's [Test Platform](https://www.browserstack.com/test-platform).
|
|
63
|
+
|
|
77
64
|
```bash
|
|
78
|
-
#
|
|
79
|
-
"run my test suite on BrowserStack"
|
|
65
|
+
# Port test suite to BrowserStack
|
|
66
|
+
"run my test suite on BrowserStack infra"
|
|
80
67
|
|
|
81
68
|
# Debug test failures
|
|
82
69
|
"My test suite failed, can you help me fix the new failures?"
|
|
@@ -85,29 +72,94 @@ BrowserStack MCP Server brings the power of BrowserStack's [Test Platform](https
|
|
|
85
72
|
"check for accessibility issues on my www.mywebsite.com"
|
|
86
73
|
```
|
|
87
74
|
|
|
75
|
+
- Fix test failures reported by your CI/CD pipeline by utilising our industry leading [Test Observability](https://www.browserstack.com/docs/test-observability) features. Find more info [here](https://www.browserstack.com/docs/test-observability/features/smart-tags).
|
|
76
|
+
- Run tests written in Jest, Playwright, Selenium, and more on BrowserStack's [Test Platform](https://www.browserstack.com/test-platform)
|
|
77
|
+
- **Accessibility Testing**: Ensure WCAG and ADA compliance with our [Accessibility Testing](https://www.browserstack.com/accessibility-testing) tool
|
|
78
|
+
|
|
79
|
+
## ๐ ๏ธ Installation
|
|
80
|
+
|
|
81
|
+
1. **Create a BrowserStack Account**
|
|
82
|
+
|
|
83
|
+
- Sign up for [BrowserStack](https://www.browserstack.com/signup) if you don't have an account already.
|
|
84
|
+
- Note down your `username` and `access_key` from [Account Settings](https://www.browserstack.com/accounts/profile/details)
|
|
85
|
+
|
|
86
|
+
2. **Install the MCP Server**
|
|
87
|
+
- VSCode (Copilot - Agent Mode): `.vscode/mcp.json`:
|
|
88
|
+
```json
|
|
89
|
+
{
|
|
90
|
+
"servers": {
|
|
91
|
+
"browserstack": {
|
|
92
|
+
"command": "npx",
|
|
93
|
+
"args": ["-y", "@browserstack/mcp-server@latest"],
|
|
94
|
+
"env": {
|
|
95
|
+
"BROWSERSTACK_USERNAME": "<username>",
|
|
96
|
+
"BROWSERSTACK_ACCESS_KEY": "<access_key>"
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
```
|
|
102
|
+
* In VSCode, make sure to click on `Start` button in the MCP Server to start the server.
|
|
103
|
+

|
|
104
|
+
|
|
105
|
+
- For Cursor: `.cursor/mcp.json`:
|
|
106
|
+
```json
|
|
107
|
+
{
|
|
108
|
+
"mcpServers": {
|
|
109
|
+
"browserstack": {
|
|
110
|
+
"command": "npx",
|
|
111
|
+
"args": ["-y", "@browserstack/mcp-server@latest"],
|
|
112
|
+
"env": {
|
|
113
|
+
"BROWSERSTACK_USERNAME": "<username>",
|
|
114
|
+
"BROWSERSTACK_ACCESS_KEY": "<access_key>"
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
```
|
|
120
|
+
- Claude Desktop: `~/claude_desktop_config.json`:
|
|
121
|
+
```json
|
|
122
|
+
{
|
|
123
|
+
"mcpServers": {
|
|
124
|
+
"browserstack": {
|
|
125
|
+
"command": "npx",
|
|
126
|
+
"args": ["-y", "@browserstack/mcp-server@latest"],
|
|
127
|
+
"env": {
|
|
128
|
+
"BROWSERSTACK_USERNAME": "<username>",
|
|
129
|
+
"BROWSERSTACK_ACCESS_KEY": "<access_key>"
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
|
|
88
137
|
## ๐ค Recommended MCP Clients
|
|
89
138
|
|
|
90
|
-
- **Github Copilot or Cursor**
|
|
91
|
-
-
|
|
139
|
+
- We recommend using **Github Copilot or Cursor** for automated testing + debugging use cases.
|
|
140
|
+
- For manual testing use cases (Live Testing), we recommend using **Claude Desktop**.
|
|
92
141
|
|
|
93
142
|
## โ ๏ธ Important Notes
|
|
94
|
-
- The BrowserStack MCP Server is under active development and currently supports a subset of the MCP protocol, i.e. `tools`. More features will be added soon.
|
|
95
|
-
- As tool invocation relies on the MCP Client which in turn rely on LLMs for tool calling. There can be some non-deterministic behaviour and can lead to unexpected results. If you have any suggestions or feedback, please open an issue to discuss.
|
|
96
|
-
|
|
97
|
-
## ๐ Contributing
|
|
98
143
|
|
|
99
|
-
|
|
144
|
+
- The BrowserStack MCP Server is under active development and currently supports a subset of the MCP spec. More features will be added soon.
|
|
145
|
+
- Tool invocations rely on the MCP Client which in turn relies on an LLM, hence there can be some non-deterministic behaviour that can lead to unexpected results. If you have any suggestions or feedback, please open an issue to discuss.
|
|
100
146
|
|
|
101
|
-
##
|
|
147
|
+
## ๐ Contributing
|
|
102
148
|
|
|
103
|
-
|
|
149
|
+
We welcome contributions! Please open an issue to discuss any changes you'd like to make.
|
|
104
150
|
|
|
105
151
|
## ๐ Support
|
|
106
152
|
|
|
107
153
|
For support, please:
|
|
154
|
+
|
|
108
155
|
- Check our [documentation](https://www.browserstack.com/docs)
|
|
109
|
-
- Open an issue in our [GitHub repository](https://github.com/browserstack/mcp-server)
|
|
110
|
-
- Contact our [support team](https://www.browserstack.com/contact)
|
|
156
|
+
- Open an issue in our [GitHub repository](https://github.com/browserstack/mcp-server) if you face any issues related to the MCP Server.
|
|
157
|
+
- Contact our [support team](https://www.browserstack.com/contact) for any other queries.
|
|
158
|
+
|
|
159
|
+
## ๐ More Features Coming Soon
|
|
160
|
+
|
|
161
|
+
Stay tuned for exciting updates! Have any suggestions? Please open an issue to discuss.
|
|
162
|
+
|
|
111
163
|
|
|
112
164
|
## ๐ Resources
|
|
113
165
|
|
|
@@ -10,7 +10,7 @@ const nodejsInstructions = `
|
|
|
10
10
|
- Add new scripts to package.json for running tests on BrowserStack (use \`npx\` to trigger the sdk):
|
|
11
11
|
\`\`\`json
|
|
12
12
|
"scripts": {
|
|
13
|
-
"test:browserstack": "npx browserstack-node-sdk <test-
|
|
13
|
+
"test:browserstack": "npx browserstack-node-sdk <framework-specific-test-execution-command>"
|
|
14
14
|
}
|
|
15
15
|
\`\`\`
|
|
16
16
|
- Add to dependencies:
|