nextjs_call
Call a specific MCP tool on a running Next.js dev server. Provide the server port and tool name. Use nextjs_index first to discover available tools, servers, and input schemas.
Instructions
Call a specific MCP tool on a running Next.js development server.
REQUIREMENTS:
Port number of the target Next.js dev server
Tool name to execute
Optional arguments object (if the tool requires parameters)
Use 'nextjs_index' first to discover available servers, tools, and their input schemas. If 'nextjs_index' auto-discovery fails, ask the user for the port and call 'nextjs_index' again with the 'port' parameter.
IMPORTANT: When calling tools:
The 'args' parameter MUST be an object (e.g., {key: "value"}), NOT a string
If a tool doesn't require arguments, OMIT the 'args' parameter entirely - do NOT pass {} or "{}"
Check the tool's inputSchema from 'nextjs_index' to see what arguments are required
Common Next.js MCP tools include:
Error diagnostics (get compilation/runtime errors)
Route information (list all routes)
Build status (check compilation state)
Cache management (clear caches)
And more (varies by Next.js version)
Example usage:
Call 'nextjs_index' to see servers and tools
Call 'nextjs_call' with port=3000, toolName="get_errors" to get errors from server on port 3000
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| port | No | Port number of the Next.js dev server (required). | |
| toolName | No | Name of the Next.js MCP tool to call (required). Use 'nextjs_index' first to discover available tool names. | |
| args | No |