Skip to main content

Create a Server

The easiest way to create a server is to use the MCPServer class from the mcp-server package. This class provides a simple way to register and manage tools, as well as execute workflows. Execute the steps defined on each tab below to create a new server, register a tool, and test a simple example.

# Create a new server, tool included in the directory `echo-tool`
npx @agentico/mcp-create-tool echo-tool

# With options
npx @agentico/mcp-create-tool echo-tool --name "MCP Echo Tool" --description "A custom MCP tool that echoes input messages."

cd echo-tool # Navigate to server directory
npm install && npm run build # Install dependencies and build once