Skip to main content
Glama
nfodor

Chromium ARM64 Browser

by nfodor

close_browser

Terminates the Chromium browser instance to free system resources on ARM64 devices after completing automation tasks or web testing workflows.

Instructions

Close the browser instance

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Core implementation of the close_browser MCP tool. Closes WebSocket connection, terminates Chromium process with graceful shutdown handling, resets globals, and returns success response.
    async closeBrowser() { if (wsConnection) { wsConnection.close(); wsConnection = null; } if (chromiumProcess && chromiumProcess.exitCode === null) { chromiumProcess.kill('SIGTERM'); // Wait for graceful shutdown await new Promise(resolve => { chromiumProcess.on('exit', resolve); setTimeout(() => { chromiumProcess.kill('SIGKILL'); resolve(); }, 5000); }); chromiumProcess = null; } currentTabId = null; return { content: [{ type: 'text', text: 'Browser closed successfully' }], }; }
  • index.js:336-342 (registration)
    Registers the close_browser tool in the ListTools response, including its name, description, and empty input schema.
    name: 'close_browser', description: 'Close the browser instance', inputSchema: { type: 'object', properties: {}, }, },
  • Implementation of close_browser in the browser-only MCP server variant. Closes connection and process, resets state.
    async closeBrowser() { if (wsConnection) { wsConnection.close(); wsConnection = null; } if (chromiumProcess) { chromiumProcess.kill('SIGTERM'); chromiumProcess = null; } currentTabId = null; return { content: [{ type: 'text', text: 'Browser closed successfully' }], }; }
  • Tool registration for close_browser in the browser-only server, with schema definition.
    { name: 'close_browser', description: 'Close the browser instance', inputSchema: { type: 'object', properties: {}, }, },

Latest Blog Posts

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/nfodor/mcp-chromium-arm64'

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