
0itsuki0/mcpdemo-typescript-
Developer toolsЭта страница переведена автоматически. Технические детали смотрите в оригинале. Открыть оригинал
0itsuki0/mcpdemo-typescript - это кандидат на сервер MCP, импортированный из https://github.com/0itsuki0/mcpdemo-typescript-.
Обзор
0itsuki0/mcpdemo-typescript - это кандидат на сервер MCP, импортированный из https://github.com/0itsuki0/mcpdemo-typescript-.
Обзор (машинный перевод)
Для более подробной информации, пожалуйста, обратитесь к моей статье: Начните с протокола контекста модели. MCP-сервер и клиент с SSE и новым потоковым HTTP Авторизация MCP: новое разделение RS и AS.
Таблица содержимого
- MCP со студией
- сервер
- хост с клиентами MCP с SSE
- сервер
- клиент MCP с потоковым HTTP
- сервер
- клиент MCP (StreamableHTTP) с авторизацией Сервер авторизации
- MCP Сервер ресурсов Клиент MCP
Локальный MCP со студией
Локальный MCP сервер
Сервер MCP, который предоставляет инструмент create-mcp-server-app для хостов MCP.
Запустив этот инструмент, либо с Claude for Desktop, либо с каким-либо другим хостом, в папке рабочего стола будет создан новый проект по созданию MCP-сервера с необходимыми настройками и образцом кода.
Образцовый код будет включать следующее.
- создание экземпляра сервера
- определение доступных инструментов
- обработка исполнения инструментов
- запуск сервера
####Настройка
- Запустите
npm install, чтобы установить необходимую зависимость - Запустить
npm run build, чтобы построить проект build/index.jsбудет путь сервера, чтобы настроить в MCP хост
Тест с Клодом для настольных компьютеров
1.Загрузить Claude для настольного компьютера 2.
Эта страница переведена автоматически. Технические детали смотрите в оригинале.
README
Показан фрагмент оригинального README. Открыть оригинал.
Demo of Model Context Protocol
For more details, please refer to my article:
- Get Start with Model Context Protocol.
- MCP Server and Client with SSE & The New Streamable HTTP
- MCP Authorization: The NEW RS and AS Separation!
Table of Contents
Local MCP with stdio
Local MCP Server
An MCP server that exposes a create-mcp-server-app tool to MCP hosts.
By running this tool, either with Claude for Desktop or some other host, a new project for creating an MCP server with necessary set ups and sample code will be created in the desktop folder.
Sample Code will include the following.
- creating a server instance
- defining available tools
- handling tools execution
- starting the server
Set Up
- Run
npm installto install necessary dependency - Run
npm run buildto build the project build/index.jswill the server path to set up in the MCP host
Test with Claude for desktop
- Download Claude for Desktop
- Open the configuration file at
~/Library/Application Support/Claude/claude_desktop_config.json- If the file does not exist, create one with the same name
- Add server configuration
{
"mcpServers": {
"create-mcp-app": {
"command": "node",
"args": [
"/absolute-path-to/build/index.js"
]
}
}
}
- Save the file and restart Claude for Desktop.
- Enter the prompt create a new mcp server project. You should see a sample MCP Server project created at desktop directory with some responses indicating the success.
Local Host with MCP Clients
An OpenAI-chatbot host that uses MCP clients to connect to MCP servers.
Set up
- Set up
OPENAI_API_KEYin.env. - Add MCP server configurations to connect the host in
server-config.json.
{
"some-server-name-1": {
"command": "node",
Установка
This server does not publish a one-line install command.
Open the repository installation guide Новичок в MCP? Начните с руководства на mcpskill.org →