Example Next.js

Next.js MCP Server that routes prompts across routes using the MCP handler for group-based interactions.
  • typescript

0

GitHub Stars

typescript

Language

7 months ago

First Indexed

3 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs

You are working with an MCP Server built for Next.js that routes prompts across a group of routes using the MCP handler. It enables you to expose an MCP endpoint through a Next.js project and test client invocations against that endpoint.

How to use

To use this MCP Server, point your MCP client at the provided HTTP endpoint. A sample client command demonstrates how to invoke the server for testing.

Important notes for running on Vercel: you can use the SSE transport when a Redis instance is attached to your project (set process.env.REDIS_URL). If you enable SSE, ensure the disableSse flag is set to false in your Next.js route configuration. For efficient execution, enable Fluid compute. If you are on a Vercel Pro or Enterprise account, you may adjust maxDuration to 800. Finally, deploy the Next.js MCP template to your project. The sample client shows how to invoke the server using a test script.

Sample client invocation you can try now is shown here. It targets a live MCP server URL and runs a test client script against it.

node scripts/test-client.mjs https://mcp-for-next-js.vercel.app

Available tools

MCP Handler

Core MCP processing engine that routes client prompts to adapters and handlers within the MCP architecture.

Next.js MCP Adapter

Adapter that enables MCP servers to run on a group of Next.js routes, integrating MCP capabilities into a Next.js project.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational