ChatGPT Orchestrator MCP Server

ChatGPT Orchestrator MCP Server

Enables ChatGPT to call an orchestrator agent via a single MCP tool, currently a stub but designed to be replaced with a real agent for task execution.

Category
Visit Server

README

ChatGPT Orchestrator MCP Server

Минимальный remote MCP server на Python для схемы:

ChatGPT -> MCP server -> main orchestrator -> helper agents

На первом этапе сервер содержит один tool:

  • run_orchestrator
  • вход: goal: string
  • выход: простой JSON

Внутри сейчас стоит заглушка. Позже ее можно заменить на вызов вашего настоящего главного агента.

Почему FastMCP

FastMCP выбран потому, что он позволяет описать MCP tool обычной Python-функцией и сразу запустить remote MCP endpoint по HTTP. Для подключения в ChatGPT нужен публичный HTTPS endpoint вида /mcp.

Структура проекта

.
├── .gitignore
├── server.py
├── requirements.txt
├── Procfile
├── render.yaml
└── README.md

Локальный запуск

Требования:

  • Python 3.11+
  • pip

1. Создать виртуальное окружение

PowerShell:

python -m venv .venv
.\.venv\Scripts\Activate.ps1

Если на Windows команда python открывает Microsoft Store или не показывает версию, используйте:

py -3.11 -m venv .venv
.\.venv\Scripts\Activate.ps1

macOS/Linux:

python3 -m venv .venv
source .venv/bin/activate

2. Установить зависимости

pip install -r requirements.txt

3. Запустить сервер

python server.py

Локальный MCP endpoint:

http://localhost:8000/mcp

Обычная проверка, что сервер жив:

http://localhost:8000/health

Если клиент просит endpoint со слэшем в конце, используйте:

http://localhost:8000/mcp/

Проверка локально

Оставьте python server.py запущенным. Во втором терминале выполните:

Invoke-RestMethod http://localhost:8000/health

Ожидаемый ответ:

{
  "status": "ok"
}

Важно: если открыть http://localhost:8000/mcp в браузере или дернуть его обычным curl без MCP-заголовков, можно увидеть ошибку:

{
  "error": {
    "message": "Not Acceptable: Client must accept text/event-stream"
  }
}

Это нормально для MCP endpoint. Проверяйте /health обычным браузером, а /mcp проверяйте MCP-клиентом.

@'
import asyncio
from fastmcp import Client

async def main():
    async with Client("http://localhost:8000/mcp") as client:
        tools = await client.list_tools()
        print("TOOLS:")
        for tool in tools:
            print("-", tool.name)

        result = await client.call_tool(
            "run_orchestrator",
            {"goal": "Create an MVP launch plan"}
        )
        print("RESULT:")
        print(result)

asyncio.run(main())
'@ | python

Ожидаемый смысл ответа: сервер покажет tool run_orchestrator и вернет JSON с текстом, что заглушка приняла задачу.

Можно также проверить через MCP Inspector:

npx @modelcontextprotocol/inspector

В UI выберите transport Streamable HTTP и URL:

http://localhost:8000/mcp

Деплой на Render

Вариант через GitHub

  1. Создайте новый GitHub-репозиторий.
  2. Загрузите туда эти файлы.
  3. Откройте Render.
  4. Нажмите New -> Web Service.
  5. Подключите GitHub-репозиторий.
  6. Render обычно сам прочитает render.yaml.
  7. Если настраиваете вручную:
    • Runtime: Python
    • Build Command: pip install -r requirements.txt
    • Start Command: python server.py
  8. Нажмите Deploy.

После деплоя Render выдаст URL примерно такого вида:

https://chatgpt-orchestrator-mcp.onrender.com

Production MCP endpoint будет:

https://chatgpt-orchestrator-mcp.onrender.com/mcp

Production health endpoint для проверки в браузере:

https://chatgpt-orchestrator-mcp.onrender.com/health

Именно этот URL нужно вставлять в ChatGPT.

Как подключить к ChatGPT

  1. Откройте ChatGPT в браузере.
  2. Перейдите в Settings.
  3. Откройте Apps & Connectors или Connectors.
  4. Включите Developer Mode, если он еще выключен:
    • Advanced settings
    • Developer mode
  5. Нажмите Create или Create connector.
  6. Заполните:
    • Name: Orchestrator
    • Description: Runs my main orchestrator agent through MCP.
    • Connector URL: https://YOUR-RENDER-SERVICE.onrender.com/mcp
  7. Сохраните.
  8. В новом чате выберите этот connector/tool и попросите ChatGPT вызвать оркестратор.

Пример тестового запроса в ChatGPT

Используй Orchestrator и вызови run_orchestrator с goal:
"Составь пошаговый план запуска MVP моего продукта"

Ожидаемый ответ от tool сейчас будет примерно:

{
  "status": "ok",
  "message": "Stub orchestrator accepted the goal.",
  "goal": "Составь пошаговый план запуска MVP моего продукта",
  "next_step": "Replace call_real_orchestrator() in server.py with your real agent call."
}

Где заменить заглушку на реального агента

Откройте server.py и найдите функцию:

def call_real_orchestrator(goal: str) -> dict[str, Any]:

Сейчас она возвращает тестовый JSON. Позже замените ее тело на реальный вызов вашего главного агента.

Пример будущей замены:

def call_real_orchestrator(goal: str) -> dict[str, Any]:
    result = my_main_agent.run(goal)
    return {
        "status": "ok",
        "goal": goal,
        "result": result,
    }

Важно: не создавайте отдельный MCP server для каждого подручного агента на первом этапе. Пусть ChatGPT видит только один tool run_orchestrator, а уже ваш главный агент внутри решает, каких подручных вызывать.

Итоговые URL

Локально:

http://localhost:8000/mcp

Production URL-шаблон:

https://YOUR-RENDER-SERVICE.onrender.com/mcp

URL для ChatGPT:

https://YOUR-RENDER-SERVICE.onrender.com/mcp

Полезные официальные документы

  • OpenAI: https://developers.openai.com/apps-sdk/deploy/connect-chatgpt
  • OpenAI: https://developers.openai.com/api/docs/mcp

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured