pool_status
Check the current status of active browser instances and available resources in the browser pool to monitor session availability and manage concurrent usage.
Instructions
Browser pool status
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- index.js:260-280 (handler)The handler function that retrieves and formats the browser pool status.
function getPoolStatus() { const status = []; for (const [port, inst] of instances) { status.push({ port, sessionId: inst.sessionId, idleMinutes: Math.round((Date.now() - inst.lastUsed) / 60000) }); } return { content: [{ type: 'text', text: JSON.stringify({ instances: status, maxInstances: MAX_INSTANCES, thisSession: sessionId, assignedPort, hasActivePage }, null, 2) }] }; - index.js:475-476 (registration)Registration of the 'pool_status' tool using the MCP server instance.
server.tool('pool_status', 'Browser pool status', {}, async () => getPoolStatus());