pause_execution
Pause the debugged Node.js process to inspect code state during debugging sessions. This tool halts execution for analysis.
Instructions
Pause execution of the debugged process
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "pause_execution"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/index.ts:612-647 (handler)The handler function for the 'pause_execution' tool. Checks if a debug session is active, then invokes Debugger.pause() via the Chrome DevTools Protocol (CDP) client to pause execution, returning appropriate success or error messages.
private async pauseExecution() { if (!this.debugSession.connected || !this.debugSession.client) { return { content: [ { type: "text", text: "No active debug session. Please attach debugger first.", }, ], isError: true, }; } try { const { Debugger } = this.debugSession.client; await Debugger.pause(); return { content: [ { type: "text", text: "Execution paused successfully", }, ], }; } catch (error) { return { content: [ { type: "text", text: `Error pausing execution: ${error}`, }, ], isError: true, }; } - src/index.ts:218-225 (registration)Registration of the 'pause_execution' tool in the tools list returned by ListToolsRequestSchema handler. Includes name, description, and empty input schema (no parameters required).
{ name: "pause_execution", description: "Pause execution of the debugged process", inputSchema: { type: "object", properties: {}, }, }, - src/index.ts:221-224 (schema)Input schema definition for the 'pause_execution' tool, specifying an empty object (no input parameters required).
inputSchema: { type: "object", properties: {}, }, - src/index.ts:262-263 (registration)Dispatch/registration case in the CallToolRequestSchema switch statement that routes calls to the pauseExecution handler.
case "pause_execution": return await this.pauseExecution();