Skip to main content
Glama

BrowserStack MCP server

Official
oninitialized.ts644 B
import { trackMCP } from "./lib/instrumentation.js"; import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js"; import { shouldSendStartedEvent } from "./lib/device-cache.js"; export function setupOnInitialized(server: McpServer, config?: any) { const nodeVersion = process.versions.node; // Check for Node.js version if (nodeVersion < "18.0.0") { throw new Error( "Node version is not supported. Please upgrade to 18.0.0 or later.", ); } server.server.oninitialized = () => { if (shouldSendStartedEvent()) { trackMCP("started", server.server.getClientVersion()!, undefined, config); } }; }

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/browserstack/mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server