ต้นแบบ · รุ่นทดลอง: มีทุก server ในทะเบียนทางการ อัปเดตทุก 30 นาที เข้าสู่ระบบด้วย Google เพื่อเขียนรีวิวได้แล้วต้นแบบ · อัปเดตทุก 30 นาที
PopNx MCPที่รวม MCP สำหรับคนใช้ AI · วิธีติดตั้งภาษาไทยทุกตัว

AI Context Flow

โดย Web3-Pluralityรุ่น 1.0.1i★ 2iรันบนคลาวด์
ชื่อใน registrynetwork.plurality/ai-context-flow

วิธีติดตั้ง

ใช้ทำอะไรได้

ยังไม่มีคำอธิบายภาษาไทย ดูข้อเท็จจริงด้านล่าง หรือเปิดคำอธิบายต้นฉบับจากผู้ทำ

  • ต่อแบบ คลาวด์ (ต่อผ่านอินเทอร์เน็ต)
  • บัญชีหรือคีย์ ล็อกอินกับบริการตอนต่อ (OAuth)
  • หมวด ค้นข้อมูลและความจำของ AI
คำอธิบายต้นฉบับจากผู้ทำ (อังกฤษ)
Universal memory for AI agents and tools. Save, organize and search context anywhere.

ติดตั้ง

เลือกโปรแกรม AI ที่คุณใช้ แล้วคัดลอกค่าตั้งไปวาง

ผลตรวจผ่าน 4/4 · สิ่งที่คุณถามผ่านเซิร์ฟเวอร์ของผู้ทำ (app.plurality.network) · ✓ ตรวจคำสั่งแล้ว 13 พ.ย. 2569

ขั้นแรก: คุณใช้ AI ตัวไหน

เลือกแอปที่คุณใช้ ขั้นตอนจะขึ้นด้านล่าง

ต่อกับ Claude ได้ · ประมาณ 2 นาที

ไม่ต้องใช้คีย์ ไม่ต้องลงโปรแกรม · ตั้งครั้งเดียวที่ claude.ai หรือแอปบนคอม แล้วใช้ในแชตได้ · บัญชีฟรีเพิ่มได้ 1 ตัว · แผน Team/Enterprise ให้เจ้าของ (Owner) เป็นคนเพิ่ม

  1. เปิดหน้า Connectors ของ Claude

    CustomizeConnectors

    CustomizeConnectors1Add2https://…3Add4
  2. กด “Add” → “Custom” → “Web” แล้วกรอก 2 ช่องนี้

    คัดลอกจากที่นี่ไปวางในช่องชื่อเดียวกันบนหน้าจอของ Claude แล้วกด Continue

    Name · ชื่อAI Context Flow
    Remote MCP server URL · ที่อยู่https://app.plurality.network/mcp

    กด Continue ผ่านหน้าตรวจการล็อกอินที่ Claude ตรวจเจอ · หัวข้อ Authentication เลือกตามที่ผู้ทำบอก (Sign in now, Sign in when needed หรือ No sign in) แล้วกด Add

  3. เปิดใช้ในแชต

    +ConnectorsAI Context Flow

  4. ลองเลย

    ใช้ AI Context Flow บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง

    ✓ ถ้า Claude บอกว่ากำลังใช้ AI Context Flow หรือมีชื่อเครื่องมือของ AI Context Flow ขึ้นในคำตอบ แปลว่าต่อสำเร็จ

ชื่อเมนูตรวจกับหน้าช่วยเหลือของ Anthropic เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป

ต่อกับ ChatGPT ได้ ขึ้นกับแผน

MCP แบบเต็ม: ChatGPT Business, Enterprise หรือ Edu บนเว็บ · Pro: ต่อได้ด้วยสิทธิ์อ่านและดึงข้อมูล เครื่องมือที่แก้ข้อมูลอาจใช้ไม่ได้ · Plus: เอกสารยังไม่ยืนยัน ถ้าเห็นเมนูเพิ่ม MCP แบบกำหนดเองในหน้าปลั๊กอิน ลองตามขั้นตอนได้ · ใช้บนเว็บเท่านั้น

  1. เปิดหน้าเพิ่ม MCP ของ ChatGPT บนเว็บ

    Plugins+Add custom MCP server

    ChatGPTPlugins1+2https://…3Create4
  2. กรอกชื่อและที่อยู่

    ใส่ชื่อ แล้ววางที่อยู่ใต้ Connection ติ๊กยอมรับคำเตือน แล้วกด Create as a plugin

    Name · ชื่อAI Context Flow
    Connection · ที่อยู่https://app.plurality.network/mcp
  3. เลือก AI Context Flow ในแชต

    เปิดแชตใหม่แล้วเลือก AI Context Flow จากรายการปลั๊กอินก่อนพิมพ์

  4. ลองเลย

    ใช้ AI Context Flow บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง

    ✓ ถ้า ChatGPT บอกว่ากำลังใช้ AI Context Flow หรือมีชื่อเครื่องมือของ AI Context Flow ขึ้นในคำตอบ แปลว่าต่อสำเร็จ

ชื่อเมนูตรวจกับหน้าช่วยเหลือของ OpenAI เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป

ต่อกับ Claude Code ได้ · ประมาณ 2 นาที

ไม่ต้องใช้คีย์ ไม่ต้องลงโปรแกรม

  1. เปิด Terminal

    Mac: กด Command+Space พิมพ์ Terminal · Windows: เปิด PowerShell

  2. วางคำสั่งนี้แล้วกด Enter

    claude mcp add --transport http --scope user ai-context-flow https://app.plurality.network/mcp
  3. พิมพ์ /mcp ใน Claude Code

    ต้องเห็น AI Context Flow ในรายการและขึ้นว่าเชื่อมต่อแล้ว

  4. ลองเลย

    ใช้ AI Context Flow บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง

    ✓ ถ้า Claude Code บอกว่ากำลังใช้ AI Context Flow หรือมีชื่อเครื่องมือของ AI Context Flow ขึ้นในคำตอบ แปลว่าต่อสำเร็จ

ชื่อเมนูตรวจกับหน้าช่วยเหลือของ Anthropic เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป

ต่อกับ Cursor ได้ · ประมาณ 2 นาที

ไม่ต้องใช้คีย์ ไม่ต้องลงโปรแกรม

  1. กดปุ่มนี้เพื่อเปิด Cursor

    เปิดใน Cursor

    Cursor จะถามยืนยันการติดตั้ง ให้กด Install

  2. เปิดแชตของ AI ใน Cursor โหมด Agent

  3. ลองเลย

    ใช้ AI Context Flow บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง

    ✓ ถ้า Cursor บอกว่ากำลังใช้ AI Context Flow หรือมีชื่อเครื่องมือของ AI Context Flow ขึ้นในคำตอบ แปลว่าต่อสำเร็จ

ชื่อเมนูตรวจกับหน้าช่วยเหลือของ Cursor เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป

ต่อกับ VS Code ได้ · ประมาณ 2 นาที

ไม่ต้องใช้คีย์ ไม่ต้องลงโปรแกรม

  1. กดปุ่มนี้เพื่อเปิด VS Code

    เปิดใน VS Code

    VS Code จะถามยืนยันการติดตั้ง ให้กด Install

  2. เปิดแชตของ AI ใน VS Code โหมด Agent

  3. ลองเลย

    ใช้ AI Context Flow บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง

    ✓ ถ้า VS Code บอกว่ากำลังใช้ AI Context Flow หรือมีชื่อเครื่องมือของ AI Context Flow ขึ้นในคำตอบ แปลว่าต่อสำเร็จ

ชื่อเมนูตรวจกับหน้าช่วยเหลือของ VS Code เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป

โปรแกรมอื่นที่ใช้ MCP ได้ เช่น Windsurf, Zed หรือ Gemini CLI มีวิธีเพิ่มต่างกัน ดูวิธีของแต่ละตัวในหน้ารวมโปรแกรม

ดูโปรแกรมที่ใช้ MCP ทั้งหมด →

ที่อยู่สำหรับโปรแกรมที่ต่อผ่านเว็บ

ที่อยู่https://app.plurality.network/mcp

ค่าตั้งแบบไฟล์ JSON อยู่ในหัวข้อ “สำหรับคนเขียนโค้ด” ด้านล่าง

ติดตรงไหน? ถามคนที่ใช้ AI Context Flow อยู่💬 พูดคุย →
สำหรับคนเขียนโค้ด: คำสั่ง Terminal และค่าตั้ง JSON

ต่อผ่านเว็บ

Claude Code

claude mcp add --transport http --scope user ai-context-flow https://app.plurality.network/mcp

Cursor (~/.cursor/mcp.json)

{
  "mcpServers": {
    "ai-context-flow": {
      "url": "https://app.plurality.network/mcp"
    }
  }
}

VS Code (mcp.json)

{
  "servers": {
    "ai-context-flow": {
      "type": "http",
      "url": "https://app.plurality.network/mcp"
    }
  }
}

ค่าตั้งนี้สร้างจากข้อมูลใน registry ของผู้ทำ ถ้าไม่ตรงกับ README ให้เชื่อ README

สรุป

ดาวน์โหลดต่อสัปดาห์i
ไม่มียอดใน npm/PyPI
โดเมนที่ยืนยัน
✓ plurality.network
licensei
ไม่ระบุ license
การเชื่อมต่อ
รันบนคลาวด์
รุ่นล่าสุดi
1.0.1
ส่งเข้า registryi
14 พ.ค. 2569
แก้โค้ดล่าสุดi
30 ส.ค. 2569
ผู้ทำ
Web3-Plurality
สถานะใน registry
ใช้งานอยู่

ใช้กับโปรแกรมไหนได้

ดูจากแบบการต่อของ server ตัวนี้ และเอกสารของผู้ทำโปรแกรมแต่ละตัว ตรวจเมื่อ 10 พ.ย. 2569

ต่อผ่านคลาวด์ได้ใน

ClaudeChatGPTGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatOpen WebUIRaycast

ดูโปรแกรมทั้งหมดพร้อมข้อดีข้อเสีย →

คู่มือที่เกี่ยวข้อง

ทำอะไรได้บ้าง

server ให้ล็อกอินก่อนจึงจะแสดงรายการเครื่องมือ

ผลตรวจเบื้องต้นi

เราตรวจจากข้อมูลที่ใครก็เปิดดูได้ ยังไม่ได้อ่านโค้ด ข้อที่ไม่เกี่ยวกับตัวนี้ไม่นับในตัวหาร · ตรวจเมื่อ 15 พ.ย. 2569

  • ✓ ผ่าน

    ตัวตนผู้ทำตรงกับ repo

    ชื่อใน registry ยืนยันโดเมน plurality.network แล้ว (registry ตรวจความเป็นเจ้าของโดเมน)

  • ✓ ผ่าน

    ยังมีคนดูแล

    มีการแก้โค้ดล่าสุด 3 เดือนที่ผ่านมา

  • – ไม่เกี่ยว

    มีสัญญาอนุญาต (license)

    ไม่เกี่ยว: server บนคลาวด์ของเจ้าของ plurality.network เอง คุณไม่ได้รันโค้ดจากรีโป

  • ✓ ผ่าน

    endpoint ตอบ

    ตอบกลับใน 556 ms (HTTP 401)

  • ✓ ผ่าน

    ล็อกอินแบบ OAuth

    ประกาศวิธีล็อกอินแบบ OAuth ให้โปรแกรม AI พาไปล็อกอินเอง

  • … ยังไม่ตรวจ

    คำอธิบายเครื่องมือไม่มีคำสั่งแอบแฝง

    ยังไม่ได้ตรวจ เราอ่านรายการเครื่องมือตอนตรวจ endpoint

เราตรวจอะไรบ้าง → · JSON

ผู้ทำ: ขอให้ตรวจใหม่ หรือแจ้งข้อมูลผิด

พูดคุย

ถาม แชร์เคล็ดลับ หรือแจ้งว่าใช้ไม่ได้ เรียงตามที่คนกดว่ามีประโยชน์

ยังไม่มีใครโพสต์ ถามหรือแชร์เป็นคนแรกได้เลย

ข้อความในส่วนนี้เขียนโดยผู้ใช้ ไม่ใช่ทีม PopNx

เข้าสู่ระบบเพื่อโพสต์

รีวิวจากผู้ใช้

ยังไม่มีรีวิว

เข้าสู่ระบบเพื่อเขียนรีวิว

เทียบกับตัวอื่นในหมวด ค้นข้อมูลและความจำของ AIi

  • ดาวมากกว่า 82% ของอีก 6157 ตัวในหมวดนี้
  • ส่งรุ่นใหม่เข้า registry ล่าสุดกว่า 11% ของอีก 6157 ตัวในหมวดนี้
  • ผลตรวจเบื้องต้นดีกว่าหรือเท่ากับ 100% ของอีก 6157 ตัวในหมวดนี้

เทียบกับทุก server ที่ยังใช้งานในหมวดนี้ทั้งทะเบียน ดาวนับเฉพาะเมื่อผู้ลงทะเบียนเป็นเจ้าของ repo

คำถามที่พบบ่อย

AI Context Flow ปลอดภัยไหม?

จากการตรวจเบื้องต้นของเรา ผ่าน 4 จาก 4 ข้อที่ตรวจได้ เรายังไม่ได้อ่านโค้ด ก่อนใส่กุญแจหรือ token ให้ดูว่า server ขอสิทธิ์อะไร และเลือกกุญแจที่ทำได้เท่าที่จำเป็น

ต้องใช้กุญแจหรือรหัสอะไรบ้าง?

registry ไม่ได้ระบุว่าต้องใช้กุญแจ แต่บางตัวจะขอให้ล็อกอินตอนใช้ครั้งแรก

ตัวนี้รันบนเครื่องหรือบนคลาวด์?

รันบนคลาวด์ของผู้ทำ ต่อผ่านอินเทอร์เน็ตได้เลย ไม่ต้องลงโปรแกรม แต่ข้อมูลที่ส่งให้จะผ่านเซิร์ฟเวอร์ของผู้ทำ

ยังมีคนดูแลอยู่ไหม?

repo บน GitHub มีการแก้โค้ดล่าสุด 3 เดือนที่ผ่านมา และส่งรุ่นล่าสุด (1.0.1) เข้า registry 6 เดือนที่ผ่านมา

ใช้กับโปรแกรมไหนได้บ้าง?

โปรแกรมที่รองรับ MCP เช่น Claude Desktop, Claude Code, Cursor และ VS Code ตัวนี้ต่อผ่าน URL จึงใช้กับโปรแกรมที่รับ remote MCP ได้ เช่น ChatGPT บนเว็บ (แบบเต็มในแผน Business ขึ้นไป · Pro แบบอ่านอย่างเดียว)

มีตัวไหนใช้แทนได้บ้าง?

ในหมวดเดียวกันมี OpenSEO, Exa, Mockserver, Microsoft Learn MCP, Docs

ตัวอื่นที่ทำงานคล้ายกัน

หมวดเดียวกันจากผู้ทำคนอื่น ผ่านตัวตรวจคำสั่งแล้ว ตัวทางการขึ้นก่อน แล้วเรียงตามดาว

อ่านการ์ด:↓ ดาวน์โหลดต่อสัปดาห์i★ ดาว GitHubiสามเสา: รีวิว · ผลตรวจ · การใช้งานiอัปเดต = วันที่ส่งรุ่นล่าสุดเข้า registryi

OpenSEO

Keyword research, site audits, rank tracking and AI visibility for your AI agent.

โดย every-appใช้กันมาก★ 27.7Kอัปเดต เมื่อวาน

รันบนคลาวด์✓ everyapp.com

Exa

Connect AI agents to Exa for web search, content fetching, and multi-step research.

โดย exa-labsใช้กันมาก★ 5.2Kอัปเดต 2 เดือนที่ผ่านมา

รันบนคลาวด์✓ เจ้าของบริการ · exa.aiทีม PopNx ลองใช้จริงแล้ว

Mockserver

Mock, record/replay, verify and chaos-test any HTTP, REST, gRPC or LLM dependency over MCP.

โดย mock-serverกำลังโต★ 5Kอัปเดต 19 วันที่ผ่านมา

รันบนเครื่อง✓ เจ้าของบริการ · mock-server.com

Microsoft Learn MCP

Official Microsoft Learn MCP Server – real-time, trusted docs & code samples for AI and LLMs.

โดย MicrosoftDocsใช้กันมาก★ 2Kอัปเดต 12 เดือนที่ผ่านมา

รันบนคลาวด์✓ เจ้าของบริการ · microsoft.comทีม PopNx ลองใช้จริงแล้ว

Docs

Search and read Empryo's documentation. Read-only, no auth, no local access.

โดย proxysoulกำลังโต★ 1.6Kอัปเดต 2 เดือนที่ผ่านมา

รันบนคลาวด์✓ empryo.com
  • OpenSEO — ใช้บนคลาวด์ ไม่ต้องลงเครื่อง · ไม่ต้องใช้คีย์
  • Exa — ใช้บนคลาวด์ ไม่ต้องลงเครื่อง · ไม่ต้องใช้คีย์ · อยู่ในคลังของ Claude
  • Mockserver — ต้องลงในเครื่อง · ไม่ต้องใช้คีย์
  • Microsoft Learn MCP — ใช้บนคลาวด์ ไม่ต้องลงเครื่อง · ไม่ต้องใช้คีย์ · อยู่ในคลังของ Claude
  • Docs — ใช้บนคลาวด์ ไม่ต้องลงเครื่อง · ไม่ต้องใช้คีย์

README จากผู้ทำ

เปิดอ่าน README

ส่วนนี้คัดจาก repo ของผู้ทำตามต้นฉบับ PopNx MCP ไม่ได้ตรวจหรือรับรองเนื้อหา ตัด HTML รูปภาพ และสคริปต์ออกแล้ว ลิงก์จะพาออกนอกเว็บ

Plurality MCP Server

Universal memory for AI agents and tools. Save, organize and search context anywhere.


An Model Context Protocol server that gives any MCP-compatible AI client persistent memory — documents, notes, conversations, and files stored across organized memory buckets with semantic search. Supports OAuth and Personal Access Tokens (PAT) based authentication.

Why use this?

  • Memory Studio — a personal knowledge base and second brain where you organize context into memory buckets, review saved content, and manage what your AI agents know.
  • Save important chats — directly from within Claude, ChatGPT, Cursor, and other AI tools into the relevant memory bucket
  • Shared persistent memory across all your agents — Claude Code, Lovable, Cursor, OpenClaw and more all access the same context
  • Semantic search — find relevant memories using natural language, not just keywords
  • Share buckets with other people — collaborate by giving others access to your context
  • Works everywhere — any MCP-compatible client can connect

We also have a Chrome extension called AI Context Flow that lets you capture and use context on any website. It comes with a built-in chat agent (30+ models) that opens as a sidebar on any page — talk to your memories, answer questions from your stored context, and surface connections across everything you've saved. You can use the MCP Server alongside the extension to get full feature set of the product.

▶️ Watch the demo

📖 Full documentation · 🌐 Website · 🧩 Chrome Extension · 🧠 Memory Studio


Quick connect (production)

Production URL: https://app.plurality.network/mcp

The server supports OAuth 2.1 with PKCE (for interactive clients) and Personal Access Tokens (for headless agents and CI). Most clients handle the OAuth flow automatically.

Works with Claude Desktop, Claude Code, ChatGPT, Cursor, and any MCP-compatible client.

→ [Step-by-step setup guides for all supported clients](https://docs.plurality.network/the-plurality-mcp-server/connect-your-agents-via-mcp)


Tools

ToolDescription
get_user_memory_bucketsList all memory buckets (organized folders) for the user
list_items_in_memory_bucketList stored items in a specific bucket (metadata only)
search_memorySemantic search across buckets with relevance scoring
read_contextRead the full content of a stored item with pagination
save_memorySave text content to a specific memory bucket
save_conversationSave a conversation (chat history) to a memory bucket
create_memory_bucketCreate a new memory bucket for organizing saved content

Authentication

The MCP server accepts two auth methods:

MethodWhen to useBrowser required?
OAuth 2.1 + PKCEInteractive clients: Claude Desktop, Web, Code, ChatGPTYes (one-time)
Personal Access Token (PAT)Headless agents, CI runners, custom integrations, n8n, LangChainNo
Using a Personal Access Token
  1. Sign in to the dashboard, open Connect via MCP → Manage tokens
  2. Click Create token, give it a name and optional expiry, copy the plur_pat_… value
  3. Configure your client to send it as a Bearer token:
Authorization: Bearer plur_pat_...

PATs require a paid plan. They auto-revoke at expiry, can be rotated with a configurable grace period (default 7 days), and can be immediately revoked from the dashboard. They are stored hashed and never appear in logs.

OAuth details

The server uses Ory Hydra as the OAuth2/OIDC provider:

PropertyValue
AlgorithmRS256
Issuerhttps://app.plurality.network (prod)
Scopeopenid offline_access mcp:tools
Access token TTL15 minutes
Refresh token TTL720 hours
Discoveryhttps://app.plurality.network/.well-known/oauth-authorization-server
Dynamic Client Registrationhttps://app.plurality.network/register

OAuth2 flow (step by step)

  1. Client discovers auth server — fetches /.well-known/oauth-protected-resource from Traefik
  2. Client registers — calls /register (Dynamic Client Registration) to get client_id/client_secret. The API Gateway proxies this to Hydra, injecting the mcp:tools scope
  3. User authenticates — browser opens Hydra's login flow, which redirects to the frontend's login/consent pages
  4. Token issued — Hydra returns a JWT access token (RS256, 15min TTL) with the user's ID as the sub claim and mcp:tools scope
  5. Authenticated requests — client includes Authorization: Bearer on all MCP requests
  6. MCP server validates — JWT signature verified locally against Hydra's JWKS public keys (cached 1 hour), mcp:tools scope is checked
  7. API Gateway access — MCP server forwards the Bearer token when calling API Gateway endpoints for data retrieval and storage

Architecture

MCP Client (Claude Code, Cursor, etc.)

│ │ OAuth2 + Streamable HTTP ▼ Traefik (:5050) ← single entrypoint for clients ├── /mcp → MCP Server (:5051) ├── /.well-known/* → API Gateway or Hydra ├── /oauth2/* → Hydra (:4444) └── /register → API Gateway (DCR proxy) │ │ Bearer token ▼ API Gateway (:5000) │ ▼ Vector Service (:8000)

Traefik is the single entrypoint. It routes OAuth traffic to Hydra and MCP protocol traffic to the MCP server. The MCP server validates JWTs locally via Hydra's JWKS keys, then forwards the Bearer token to the API Gateway for data access. The API Gateway handles authentication, DCR proxying, and routes vector/search operations to the Vector Service.


Local development setup

Prerequisites
  • Python 3.11+
  • uv (Python package manager)
  • Docker and Docker Compose
  • Running API Gateway (plurality-backend-api): Handles authentication, OAuth metadata, DCR proxying, and database access
  • Running Vector Service (plurality-ai-service): Handles semantic search and vector database operations
1. Install dependencies
cd plurality-mcp-server

pip install uv uv sync

2. Configure environment
cp .env.example .env

Default values work for local development — no changes needed if the API Gateway runs on :5000:

HYDRA_ISSUER=http://localhost:5050

MCP_RESOURCE_URL=http://localhost:5050 BACKEND_API_URL=http://localhost:5000

3. Start Docker services (Hydra + Traefik)
cd ory-hydra

docker compose up -d

This starts:

ServicePortPurpose
PostgreSQL5433Hydra's database
Hydra4444, 4445OAuth2/OIDC provider (public + admin)
Traefik5050Reverse proxy / routing

Wait for services to be healthy: docker compose ps

4. Start the MCP server
uv run uvicorn main:mcp_server --host 0.0.0.0 --port 5051 --reload

Port 5051, not 5050. Traefik listens on 5050 and proxies /mcp to the MCP server on 5051.

5. Verify
# Health check (direct)

curl http://localhost:5051/mcp/health

OAuth metadata (via Traefik)

curl http://localhost:5050/.well-known/oauth-protected-resource

Traefik dashboard (for debugging routes)

open http://localhost:8080

Local client configuration

Claude Code

claude mcp add --transport http plurality-memory http://localhost:5050/mcp

Then authenticate via /mcp inside Claude Code.

Claude Code — VS Code Extension

Authenticate first in the terminal using the steps above. Then add .mcp.json to your project root:

{

"mcpServers": { "plurality-memory": { "type": "http", "url": "http://localhost:5050/mcp" } } }

The VS Code extension may not trigger the OAuth browser flow automatically. Complete authentication via the terminal first.

Claude Desktop

Edit your config file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
{

"mcpServers": { "plurality-memory": { "command": "npx", "args": ["mcp-remote", "http://localhost:5050/mcp"] } } }

Restart Claude Desktop fully, then authenticate when the browser opens.

MCP Inspector (debugging)

npx @modelcontextprotocol/inspector

Enter http://localhost:5050/mcp as the server URL. The inspector walks through the OAuth flow and lets you call tools interactively.

Note: ChatGPT is not supported for local development — it requires publicly reachable OAuth endpoints.


Project structure

plurality-mcp-server/

├── main.py # Entry point ├── pyproject.toml # Dependencies (managed by uv) ├── .env.example # Environment template ├── src/plurality_mcp_server/ │ ├── app.py # FastMCP app + middleware stack │ ├── config.py # Env vars, shared HTTP client, context vars │ ├── auth.py # JWT validation via Hydra JWKS + scope check │ └── tools.py # MCP tool definitions (read + write) └── ory-hydra/ ├── docker-compose.yml # Hydra + Traefik + PostgreSQL ├── hydra.yml # Hydra OAuth2/OIDC config ├── traefik.yml # Traefik static config └── dynamic.yml # Traefik routing rules


Troubleshooting

MCP client gets 401 Unauthorized

  • Check that Hydra is running: curl http://localhost:4444/.well-known/openid-configuration
  • Check that the JWT hasn't expired (15min TTL)
  • Verify HYDRA_ISSUER matches the issuer in the token's iss claim
  • Ensure the token has the mcp:tools scope

MCP client gets 502 Bad Gateway

  • The MCP server isn't running on port 5051
  • Check Traefik logs: docker compose -f ory-hydra/docker-compose.yml logs traefik

Tools return "Error: Backend API returned status 401" </summar

ตัดมาแค่ช่วงต้น อ่านต่อใน repo