adonis
An AdonisJS package for building remote MCP servers
claude mcp add --transport stdio 7nohe-adonis-mcp npx -y @7nohe/adonis-mcp
How to use
Adonis MCP adds support for the Model Context Protocol (MCP) to an AdonisJS project, enabling you to serve remote MCP resources and tools via Server-Sent Events (SSE). After installing and configuring, you register the MCP routes and tools in your Adonis app, define prompts and resources, and expose an SSE endpoint along with a messages endpoint. The server empowers clients to discover, query, and interact with tools and prompts defined in your Adonis application, using the MCP SDK structures exposed by the package. Start by wiring your routes in start/routes.ts, then launch your Adonis server and connect via SSE to the configured endpoints.
How to install
Prerequisites:
- Node.js installed
- An existing AdonisJS project
- Install the MCP package in your Adonis project:
node ace add @7nohe/adonis-mcp
- Generate and edit the MCP configuration:
- After installation, a config/mcp.ts file will be generated.
- Open config/mcp.ts and customize the endpoints and server options, for example:
import { defineConfig } from '@7nohe/adonis-mcp'
export default defineConfig({
ssePath: '/sse',
messagesPath: '/messages',
serverOptions: {
name: 'mymcp',
version: '0.0.1',
},
})
- Start the Adonis server (which also starts the MCP server via the package integration):
npm run dev
- Verify the MCP server is running at the configured SSE endpoint (e.g., http://localhost:3333/sse) and the messages endpoint (e.g., http://localhost:3333/messages).
Additional notes
Tips:
- The MCP server in Adonis uses SSE to stream updates and responses to clients. Ensure your frontend or client supports SSE.
- You can customize paths via ssePath and messagesPath in config/mcp.ts.
- Use serverOptions.name and version to identify your MCP server in logs and responses.
- If you encounter CORS issues during development, ensure your Adonis app is accessible from the client origin or enable appropriate CORS settings in your Adonis config.
- The inspector tool can be used for debugging MCP connections by pointing it to http://localhost:3333/sse when the server is running.
Environment variables:
- No required environment variables are documented for this package beyond your standard AdonisJS environment. You can add placeholders in mcp_config.env if you plan to inject runtime values.
Related MCP Servers
mcp-graphql
Model Context Protocol server for GraphQL
anytype
An MCP server enabling AI assistants to interact with Anytype - your encrypted, local and collaborative wiki - to organize objects, lists, and more through natural language.
tableau
Tableau's official MCP Server. Helping Agents see and understand data.
mcp -circleci
A specialized server implementation for the Model Context Protocol (MCP) designed to integrate with CircleCI's development workflow. This project serves as a bridge between CircleCI's infrastructure and the Model Context Protocol, enabling enhanced AI-powered development experiences.
one-search
🚀 OneSearch MCP Server: Web Search & Scraper & Extract, Support agent-browser, SearXNG, Tavily, DuckDuckGo, Bing, etc.
kollektiv
Kollektiv MCP enables you to chat with and query your own documents directly from IDEs and MCP clients. Private, secure, and integrated into your favorite code editor