@browserstack/mcp-server 1.5.1-beta.1 → 1.5.1-beta.2

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.
@@ -9,15 +9,6 @@ import { handleMCPError } from "../lib/utils.js";
9
9
  import { trackMCP } from "../index.js";
10
10
  import { NEEDS_BUILD_ID, NEEDS_TEST_IDS } from "./tool-handoff.js";
11
11
  import { FETCH_RCA_PARAMS, GET_BUILD_ID_PARAMS, LIST_TEST_IDS_PARAMS, } from "./rca-agent-utils/constants.js";
12
- function describeBuildIdError(error, args) {
13
- const status = error?.response
14
- ?.status;
15
- const message = error instanceof Error ? error.message : "Unknown error";
16
- if (status === 404 || /\b404\b/.test(message)) {
17
- return `No build found for project "${args.browserStackProjectName}" and build "${args.browserStackBuildName}". Both names must match the BrowserStack Automate dashboard exactly.`;
18
- }
19
- return message;
20
- }
21
12
  // Tool function to fetch build ID
22
13
  export async function getBuildIdTool(args, config) {
23
14
  try {
@@ -35,7 +26,7 @@ export async function getBuildIdTool(args, config) {
35
26
  };
36
27
  }
37
28
  catch (error) {
38
- const errorMessage = describeBuildIdError(error, args);
29
+ const errorMessage = error instanceof Error ? error.message : "Unknown error";
39
30
  logger.error("Error fetching build ID: %s", errorMessage);
40
31
  return {
41
32
  content: [
@@ -65,7 +56,7 @@ export async function listBuildIdTool(args, config) {
65
56
  };
66
57
  }
67
58
  catch (error) {
68
- const errorMessage = describeBuildIdError(error, args);
59
+ const errorMessage = error instanceof Error ? error.message : "Unknown error";
69
60
  logger.error("Error fetching build ID: %s", errorMessage);
70
61
  return {
71
62
  content: [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@browserstack/mcp-server",
3
- "version": "1.5.1-beta.1",
3
+ "version": "1.5.1-beta.2",
4
4
  "description": "BrowserStack's Official MCP Server",
5
5
  "mcpName": "io.github.browserstack/mcp-server",
6
6
  "main": "dist/index.js",