Dev Servers as Agent-Readable Runtime APIs
maps to joelclaw.com web work because coding agents can query live Next.js errors, routes, page metadata, and logs instead of guessing from files
Next.js added Model Context Protocol support that lets coding agents talk to a running app through the dev server. Not just read files. Not just scrape terminal output. The app exposes live state through /_next/mcp, and next-devtools-mcp connects an agent to it.
That is the useful bit: the development server becomes an agent-readable runtime API. An agent can ask for current errors, logs, page metadata, project metadata, routes, and Server Actions by ID. That is much better than watching an agent hallucinate what the browser is probably doing based on a stack trace from six minutes ago.
For joelclaw, this belongs in the default Next.js agent loop for web work. Agents touching joelclaw.com should be able to ask the app what routes exist, what page is rendering, what errors are live, and where the logs are. Pair it with Playwright MCP, and the loop gets both runtime diagnostics and browser verification. Joel’s Slack note was blunt: “definitely use this”.
Key Ideas
Next.js 16+includes a built-inMCPendpoint at/_next/mcpinside the development server.next-devtools-mcpis configured through.mcp.jsonand automatically discovers runningNext.jsinstances.- The tool surface includes
get_errors,get_logs,get_page_metadata,get_project_metadata,get_routes, andget_server_action_by_id. - The documented workflow is simple: start the
Next.jsdev server, let the coding agent connect throughnext-devtools-mcp, open the app in a browser, then query diagnostics from the agent. - The docs explicitly connect this to
Cache Components,Next.jsmigrations, codemods, andPlaywright MCPbrowser testing.