0M

0itsuki0/mcpdemo-typescript-

Developer tools

Эта страница переведена автоматически. Технические детали смотрите в оригинале. Открыть оригинал

39 stars 12 forks Качество 50 Тренд 12

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-сервера с необходимыми настройками и образцом кода.

Образцовый код будет включать следующее.

  • создание экземпляра сервера
  • определение доступных инструментов
  • обработка исполнения инструментов
  • запуск сервера

####Настройка

  1. Запустите npm install, чтобы установить необходимую зависимость
  2. Запустить npm run build, чтобы построить проект
  3. build/index.js будет путь сервера, чтобы настроить в MCP хост

Тест с Клодом для настольных компьютеров

1.Загрузить Claude для настольного компьютера 2.

Эта страница переведена автоматически. Технические детали смотрите в оригинале.

README

Показан фрагмент оригинального README. Открыть оригинал.

Demo of Model Context Protocol

For more details, please refer to my article:

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

  1. Run npm install to install necessary dependency
  2. Run npm run build to build the project
  3. build/index.js will the server path to set up in the MCP host

Test with Claude for desktop

  1. Download Claude for Desktop
  2. 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
  3. Add server configuration
{
    "mcpServers": {
        "create-mcp-app": {
            "command": "node",
            "args": [
                "/absolute-path-to/build/index.js"
            ]
        }
    }
}
  1. Save the file and restart Claude for Desktop.
  2. 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

  1. Set up OPENAI_API_KEY in .env.
  2. Add MCP server configurations to connect the host in server-config.json.
{
    "some-server-name-1": {
        "command": "node",
Открыть полный README на GitHub

Установка

This server does not publish a one-line install command.

Open the repository installation guide Новичок в MCP? Начните с руководства на mcpskill.org →