Skip to content

DevTools Protocol

Connect to Multilogin X browser profiles using Chrome DevTools Protocol (CDP) for advanced automation and debugging.

Getting the WebSocket URL

From Profile Start Response

When starting a profile with automation_type=playwright or automation_type=puppeteer, the response includes connection details.

Via Debugger URL Endpoint

GET /api/v1/profile/p/:profile_id/ws_debugger_url

Get the CDP WebSocket debugger URL for a running profile:

bash
curl "https://launcher.mlx.yt:45001/api/v1/profile/p/PROFILE_ID/ws_debugger_url" \
  -H "Authorization: Bearer YOUR_TOKEN"

CDP Connection

javascript
const WebSocket = require('ws');

const ws = new WebSocket('ws://127.0.0.1:PORT/devtools/browser/BROWSER_ID');

ws.on('open', () => {
    // Send CDP commands
    ws.send(JSON.stringify({
        id: 1,
        method: 'Page.navigate',
        params: { url: 'https://example.com' }
    }));
});

ws.on('message', (data) => {
    console.log(JSON.parse(data));
});

Use Cases

  • Advanced page inspection -- Access DOM, network, console data
  • Performance monitoring -- CPU, memory, network profiling
  • Custom automation -- Low-level browser control beyond Selenium/Playwright
  • Debugging -- Inspect running profile state
  • Screenshots -- Capture page screenshots programmatically

CDP vs WebDriver

FeatureCDP (DevTools Protocol)WebDriver (Selenium)
LevelLow-level browser APIHigh-level abstraction
SpeedFasterStandard
AccessFull browser internalsPage-level only
StandardChrome-specificW3C standard
Best forCustom automationStandard testing