Skip to main content
Glama

BrowserStack MCP server

Official
utils.ts1.26 kB
const content: { type: "text"; text: string }[] = []; export async function updateFileAndStep( file: string, idx: number, total: number, instruction: string, ) { content.length = 0; const nextIndex = idx + 1; content.push({ type: "text", text: `Complete all steps in order. If a tool call is requested, update the file first, then call the tool. Follow instructions exactly— do not skip any steps to ensure all files are updated.`, }); content.push({ type: "text", text: `Step 1 : You need to add percy snapshot commands in some key test cases in the file ${file} use the following instructions: \n${instruction}`, }); content.push({ type: "text", text: `Step 2 : Confirm that Percy snapshot commands have been added at all key points of visual change in the file ${file}.`, }); if (nextIndex < total) { content.push({ type: "text", text: `Step 3 : Call the tool updateTestFileWithInstructions with index as ${nextIndex} out of ${total}`, }); } if (nextIndex === total) { content.push({ type: "text", text: `Step 3: Percy snapshot commands have been added to all files. You can now run the tool runPercyScan to run the percy scan.`, }); } return content; }

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