set_breakpoint
Set breakpoints at specific code lines to pause execution and inspect application state, with optional conditional expressions for precise debugging.
Instructions
Sets a breakpoint at a specific location in the code. The breakpoint will pause execution when the specified line is reached. You can set conditional breakpoints that only trigger when an expression evaluates to true.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| session_id | Yes | ID of the debugging session. | |
| url | Yes | URL of the script where the breakpoint should be set. For Node.js, use file:// URLs (e.g., file:///path/to/script.js). For remote scripts, use the full URL. Use list_scripts to find available scripts. | |
| line_number | Yes | Line number (0-based) where the breakpoint should be set. Note: Most editors display 1-based line numbers, so subtract 1. | |
| column_number | No | Optional column number (0-based). Useful for setting breakpoints in minified code. | |
| condition | No | Optional JavaScript expression. The breakpoint only triggers when this expression evaluates to true. Example: "count > 100" or "user.name === 'admin'" |