intercept_electron
Launch Electron applications while intercepting their HTTP(S) traffic for debugging and inspection purposes.
Instructions
Launch an Electron application with all its HTTP(S) traffic intercepted. Use get_interceptor_metadata with id "electron" to list available Electron apps.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| proxyPort | Yes | Proxy port to route traffic through | |
| pathToApplication | Yes | Path to the Electron application to launch |
Implementation Reference
- src/index.ts:315-327 (registration)Registration of the 'intercept_electron' tool in the MCP server.
server.registerTool( 'intercept_electron', { title: 'Intercept Electron App', description: 'Launch an Electron application with all its HTTP(S) traffic intercepted. Use get_interceptor_metadata with id "electron" to list available Electron apps.', inputSchema: z.object({ proxyPort: z.number().describe('Proxy port to route traffic through'), pathToApplication: z.string().describe('Path to the Electron application to launch'), }), }, async ({ proxyPort, pathToApplication }) => jsonResult(await client.activateInterceptor('electron', proxyPort, { pathToApplication })) ); - src/httptoolkit-client.ts:101-110 (handler)The handler implementation that makes the HTTP request to the HTTP Toolkit server to activate an interceptor.
async activateInterceptor( id: string, proxyPort: number, options?: unknown ): Promise<{ result: { success: boolean; metadata?: unknown } }> { return this.request( 'POST', `/interceptors/${encodeURIComponent(id)}/activate/${proxyPort}`, options || {} );