
Mcp Server Basic Sample
Prepare mcp server app
1. Install packages
pnpm install
2. Build
pnpm build
Mcp Inspector
Inspector - Model Context Protocol
pnpm start
pnpm inspect
Claude for Desktop
Download Claude for Desktop
Set Configure Claude for Desktop
Open the config file in VSCode.
code ~/Library/Application\ Support/Claude/claude_desktop_config.json
/Users/[user]/Library/Application Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"RandomNumber": {
"command": "node",
"args": ["/ABSOLUTE/PATH/TO/PARENT/FOLDER/build/index.js"]
}
}
}
If you use mise.
$ mise which node
/Users/[user]/.local/share/mise/installs/node/22.14.0/bin/node
/Users/[user]/Library/Application Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"RandomNumber": {
"command": "/Users/[user]/.local/share/mise/installs/node/22.14.0/bin/node",
"args": ["/ABSOLUTE/PATH/TO/PARENT/FOLDER/build/index.js"]
}
}
}
reference: https://github.com/modelcontextprotocol/servers/issues/64#issuecomment-2503152420
Resources
相关推荐
Confidential guide on numerology and astrology, based of GG33 Public information
Take an adjectivised noun, and create images making it progressively more adjective!
Siri Shortcut Finder – your go-to place for discovering amazing Siri Shortcuts with ease
Reviews

user_GnvgxFKW
As a dedicated user of mcp applications, I found the mcp-server-basic-sample to be incredibly useful. The seamless setup and clear documentation by t-shiratori make it an ideal choice for those looking to understand server integration with random number generation. The repository (https://github.com/t-shiratori/mcp-server-example-random-num) offers a great starting point, and the welcoming message ensures an easy onboarding experience. Highly recommended for both beginners and experienced users!