mcp-chatgpt
MCP server that lets AI assistants interact with ChatGPT Web via browser automation, enabling chat, web search, file/image attachments, and model selection.
README
🚀 mcp-chatgpt
เซิร์ฟเวอร์ Model Context Protocol (MCP) ประสิทธิภาพสูง สำหรับเชื่อมต่อ AI Client (เช่น Claude Desktop, Cursor, Cline, Antigravity) เข้ากับ ChatGPT Web เป็นเครื่องยนต์หลัก พร้อมรองรับ Google Gemini, Z.ai (GLM-5.2) และ Kimi AI (K3) ผ่าน Chrome Extension Bridge หรือ Playwright Automation โดยตรงจากโปรไฟล์เบราว์เซอร์ในเครื่องของคุณ
🌟 ฟีเจอร์เด่น (Key Features)
- 🟢 ChatGPT Web First (หลัก): สนทนาต่อเนื่อง, ค้นหาเว็บ (
web_search), วิเคราะห์ไฟล์/รูปภาพ, เลือกโมเดล (GPT-4o, o3-mini) และเลือกระดับการคิด (reasoning_effort: High / Medium / Low) - 🔌 Chrome Extension Bridge: เชื่อมต่อตรงกับแท็บเบราว์เซอร์ที่เปิดอยู่แบบ Real-time ไม่ต้องล็อกอินซ้ำ และไม่รบกวนการทำงานปกติ
- 🌐 Multi-Provider Support (เสริม): สลับไปใช้งาน Google Gemini, Z.ai (GLM-5.2 Deep Think) หรือ Kimi AI (K3) ได้ในระบบเดียว
- 📁 Workspace & Shell Tools: มีเครื่องมือสั่งรันคำสั่ง Shell (
shell_command) และแก้ไขไฟล์ (apply_patch) อย่างปลอดภัยภายในโปรเจกต์ - 👤 Chrome Profile Selector: ตรวจจับและสลับโปรไฟล์ Chrome ที่มีอยู่ในเครื่องอัตโนมัติ
- 🔒 Local & Remote MCP: รองรับทั้งโหมด Local stdio สำหรับใช้งานในเครื่อง และโหมด Remote Streamable HTTP (พร้อม Bearer Token Auth และ Cloudflare Tunnel)
🛠️ รายการ MCP Tools (Tools Reference)
1. เครื่องมือหลัก ChatGPT & Unified
| Tool Name | คำอธิบาย | พารามิเตอร์หลัก |
|---|---|---|
chatgpt_ask |
ส่งคำถามไปยัง ChatGPT Web | message, model, reasoning_effort, web_search, file_paths, image_paths, conversation_id, new_chat |
chatgpt_new_chat |
เริ่มต้นบทสนทนาใหม่บน ChatGPT | - |
chatgpt_list_conversations |
ดึงประวัติรายการบทสนทนาล่าสุด | limit (ค่าเริ่มต้น: 20) |
chatgpt_list_models |
ดึงรายชื่อโมเดลที่บัญชีสามารถใช้งานได้ | - |
chatgpt_get_status |
ตรวจสอบสถานะการเชื่อมต่อและการล็อกอิน | - |
llm_ask |
สั่งคำถามไปยัง Provider ใดก็ได้ | message, provider (chatgpt | gemini | kimi | zai), model |
2. เครื่องมือ Multi-Provider (เสริม)
| Provider | Tools | ความสามารถเด่น |
|---|---|---|
| Google Gemini | gemini_ask, gemini_new_chat, gemini_get_status |
เชื่อมต่อ gemini.google.com/app ค้นหาแท็บอัตโนมัติ |
| Z.ai | zai_ask, zai_new_chat, zai_get_status |
เชื่อมต่อ chat.z.ai รองรับโมเดล GLM-5.2 Deep Think |
| Kimi AI | kimi_ask, kimi_new_chat, kimi_get_status |
เชื่อมต่อ kimi.ai รองรับดีไซน์ใหม่ K3 ProseMirror |
3. เครื่องมือ Workspace & Profiles
| Tool Name | คำอธิบาย | พารามิเตอร์หลัก |
|---|---|---|
shell_command |
รันคำสั่ง Shell ในไดเรกทอรีโปรเจกต์อย่างปลอดภัย | command, workdir, timeout_ms, shell |
apply_patch |
แก้ไข/เขียนทับเนื้อหาไฟล์ในโปรเจกต์ | patch (V4 format) |
chatgpt_list_profiles |
แสดงรายการโปรไฟล์ Chrome ที่พบบนเครื่อง | - |
chatgpt_select_profile |
เลือกโปรไฟล์ Chrome สำหรับใช้งาน | profile |
📦 การติดตั้งและการเตรียมความพร้อม (Installation)
1. ติดตั้ง Dependencies และ Build โปรเจกต์
git clone https://github.com/JonusNattapong/mcp-chatgpt.git
cd mcp-chatgpt
npm install
npm run build
2. ติดตั้ง Chrome Extension Bridge (แนะนำ)
- เปิด Google Chrome แล้วไปที่
chrome://extensions/ - เปิดสวิตช์ Developer mode ที่มุมขวาบน
- คลิก Load unpacked แล้วเลือกโฟลเดอร์
extensionภายในโปรเจกต์นี้ - คลิกไอคอนส่วนขยาย MCP Web LLMs Bridge เพื่อเปิดใช้งาน
⚙️ การตั้งค่าใน AI Client (Configuration)
1. Claude Desktop / Cursor / Antigravity IDE (claude_desktop_config.json)
{
"mcpServers": {
"chatgpt-bridge": {
"command": "node",
"args": ["D:/Projects/Github/mcp-chatgpt/dist/index.js"]
}
}
}
2. เปิดใช้งานแบบ Remote HTTP Server (พร้อม Bearer Auth)
# รัน HTTP Server พอร์ต 8686
node dist/index.js --http 8686 --auth-token "your-secret-token"
# หรือเชื่อมต่อผ่าน Cloudflare Tunnel
node dist/index.js --http 8686 --tunnel
🧪 การทดสอบระบบ (Testing)
# รัน Unit Tests ทั้งหมด
npm test
# รัน Bridge Mode อย่างเดียว
npm run bridge
📄 License
MIT License © 2026 JonusNattapong
Recommended Servers
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.
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.
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.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
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.
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.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
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.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.