MCPSERV.CLUB
shricodev

Chat Nextjs MCP Client

MCP Server

AI chatbot interface for local and remote MCP servers

Stale(60)
30stars
2views
Updated 21 days ago

About

A Next.js 14+ demo app that connects to Model Context Protocol (MCP) servers—both hosted via Composio and local filesystem—providing a styled chat UI with tool‑calling support for Gmail, Linear, Slack and more.

Capabilities

Resources
Access data sources
Tools
Execute functions
Prompts
Pre-built templates
Sampling
AI model interactions

Overview

The Chat Next.js MCP Client is a lightweight, fully‑functional chat interface that demonstrates how an AI assistant can be wired to external data sources and tools using the Model Context Protocol (MCP). It solves a common pain point for developers: repeatedly building custom chat UIs that can talk to both remote and local MCP servers while still supporting rich tool‑calling capabilities. By abstracting away the plumbing of MCP, this project lets teams focus on designing user experiences rather than implementing protocol logic from scratch.

At its core, the server exposes a Next.js front‑end that communicates with any MCP endpoint—whether hosted by Composio or running locally on the developer’s machine. The client handles authentication, request routing, and streaming responses from the AI model. It also integrates seamlessly with a range of external services (Gmail, Linear, Slack, etc.) via MCP’s tool‑calling mechanism. When the assistant decides to perform an action—such as sending an email or creating a GitHub issue—the client forwards the tool request to the MCP server, which in turn invokes the appropriate integration. The response is streamed back to the chat UI, giving users real‑time feedback.

Key capabilities include:

  • Dual server support: Switch effortlessly between a hosted Composio MCP server and a local file‑system server, making the same UI work in both development and production scenarios.
  • Rich tool calling: The client can invoke a wide array of tools (email, issue trackers, project management apps) without any custom code. The MCP server handles authentication and execution behind the scenes.
  • Real‑time streaming: AI responses are streamed to the UI, creating a natural conversational feel and reducing perceived latency.
  • Modular design: The code is split into reusable components (chat UI, autoresizing textarea, MCP client utilities) and follows Next.js App Router conventions, enabling easy extension or replacement.

Typical use cases include building internal chatbots that automate routine tasks (scheduling meetings, posting updates to Slack, managing tickets), creating customer support assistants that can pull real‑time data from CRM systems, or prototyping new AI workflows without investing in custom backend logic. Because the client is agnostic to the underlying MCP server, teams can iterate locally with a lightweight setup and then deploy to a managed Composio service for production scalability.

In summary, the Chat Next.js MCP Client offers developers a plug‑and‑play starting point for AI‑powered applications that need to interact with external tools and data. It showcases MCP’s strengths—tool calling, real‑time streaming, and server flexibility—in a polished UI that can be adapted to many business scenarios.