Example MCP Server

Example MCP server demonstrating framework usage

Local serverstdioTypeScript

What is the Example MCP server?

Connect Example to Claude, Cursor or any other MCP client and it stops being a tab you switch to. Example MCP server demonstrating framework usage. The example mcp server is what makes that connection.

What the server does

A production-ready MCP (Model Context Protocol) server built with TypeScript featuring both basic tools and advanced LLM-powered capabilities with type-safe provider and model selection and dual-mode operation (STDIO + Streamable HTTP with OAuth).

Available tools

The toolset is worth reading before you wire it up, because it tells you what the integration is really for:

  • hello — Greets a person by name
  • echo — Echoes back a provided message
  • current-time — Returns the current timestamp
  • chat — Interactive AI assistant using Claude Haiku (fast responses)
  • analyze — Deep text analysis using GPT-4 (sentiment, themes, structure)
  • summarize — Text summarization using Gemini Flash (cost-effective)
  • explain — Educational explanations using Claude (clear, adaptive to level)
  • OpenAIhttps://platform.openai.com/api-keys
  • Features — The Features tool exposed by this server
  • Documentation — The Documentation tool exposed by this server

Installation

Installation goes through your MCP client rather than a global install: point it at tsx on npm and it is fetched when the client starts. The copy-paste blocks for Claude Desktop, Claude Code and Cursor are further down this page.

Credentials and setup notes

Configuration is passed through the environment: ANTHROPIC_API_KEY, OPENAI_API_KEY, GOOGLE_API_KEY, GOOGLE_CLIENT_ID, GITHUB_CLIENT_ID, MICROSOFT_CLIENT_ID. Treat anything key-shaped as a real credential — scope it to the minimum the server needs, and rotate it if it ever lands in a shared config.

  • Node.js 22+ (Current LTS) - Docker (via Colima on macOS) - Optional: API keys for LLM providers (Anthropic, OpenAI, Google)

Where it fits

This sits in the AI and media services group, where several servers overlap in what they claim to do but differ sharply once you actually set them up. Example's toolset — hello, echo, current-time and 7 more — is a fair guide to whether it matches your workflow. It is maintained by jeffrdutton; worth a glance at recent repository activity before you build anything load-bearing on it.

This entry was verified against Example's own documentation before publication; SyncDev keeps the directory reviewed rather than auto-generated.

Worth knowing first

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • With 10 tools registered it takes up a noticeable share of the context window; turn it off in projects that never touch Example.
  • Missing credentials fail quietly in some clients — if no tools show up, check the environment block first.
  • Keep per-call confirmation enabled while you learn its behaviour; it is the cheapest safeguard you have.

Available tools

ToolWhat it does
helloGreets a person by name
echoEchoes back a provided message
current-timeReturns the current timestamp
chatInteractive AI assistant using Claude Haiku (fast responses)
analyzeDeep text analysis using GPT-4 (sentiment, themes, structure)
summarizeText summarization using Gemini Flash (cost-effective)
explainEducational explanations using Claude (clear, adaptive to level)
OpenAIhttps://platform.openai.com/api-keys
FeaturesThe Features tool exposed by this server.
DocumentationThe Documentation tool exposed by this server.

How to install the Example MCP server

{
  "mcpServers": {
    "example-1": {
      "command": "npx",
      "args": ["-y", "tsx"],
      "env": {
        "ANTHROPIC_API_KEY": "your-value",
        "OPENAI_API_KEY": "your-value",
        "GOOGLE_API_KEY": "your-value",
        "GOOGLE_CLIENT_ID": "your-value",
        "GITHUB_CLIENT_ID": "your-value",
        "MICROSOFT_CLIENT_ID": "your-value"
      }
    }
  }
}

Add to claude_desktop_config.json, then restart Claude Desktop.

Configuration

  • Node.js 22+ (Current LTS) - Docker (via Colima on macOS) - Optional: API keys for LLM providers (Anthropic, OpenAI, Google)
VariableDescriptionRequired
ANTHROPIC_API_KEYCredential the server authenticates with.Yes
OPENAI_API_KEYCredential the server authenticates with.Yes
GOOGLE_API_KEYCredential the server authenticates with.Yes
GOOGLE_CLIENT_IDConfiguration value read at startup.Optional
GITHUB_CLIENT_IDConfiguration value read at startup.Optional
MICROSOFT_CLIENT_IDConfiguration value read at startup.Optional

Example prompts to try

  • Use Example to hello.
  • Use Example to echo.
  • Use Example to current-time.

Frequently asked questions

It connects Example to MCP-compatible AI assistants such as Claude and Cursor, exposing 10 tools (hello, echo, current-time, and more) that the assistant can call on your behalf. Instead of copying data back and forth by hand, the assistant works with Example directly.