ข้ามไปยังเนื้อหา

เริ่มต้น

เชื่อมต่อเครื่องมือ AI

คลังคอมโพเนนต์มีเซิร์ฟเวอร์ MCP ให้เครื่องมือ AI อ่านทุกอย่างที่เว็บนี้มี: คอมโพเนนต์ทุกตัว props กฎของหน้าจอ ตัวอย่าง HTML ที่แสดงจริง ซอร์สโค้ด CSS และบันทึกการเปลี่ยนแปลง เชื่อมต่อแล้ว AI จะสร้างและแก้หน้าจอจากคอมโพเนนต์ได้ถูกต้อง

ที่อยู่ของเซิร์ฟเวอร์

Streamable HTTP อ่านอย่างเดียว ไม่บันทึกหรือแก้ไขอะไร ไม่ต้องเข้าสู่ระบบ

https://test.bsru-components.plusdet.com/mcp

ตั้งค่าในเครื่องมือของคุณ

Claude Code

รันคำสั่งนี้ครั้งเดียวในเทอร์มินัล ใช้ได้ทุกโปรเจกต์

claude mcp add --scope user --transport http bsru-components https://test.bsru-components.plusdet.com/mcp

Claude Code, one project

วางไฟล์ .mcp.json ที่รากของโปรเจกต์ ทุกคนในทีมได้เหมือนกัน

{
  "mcpServers": {
    "bsru-components": {
      "type": "http",
      "url": "https://test.bsru-components.plusdet.com/mcp"
    }
  }
}

Claude Desktop and claude.ai

Settings แล้ว Connectors แล้ว Add custom connector ตั้งชื่อ bsru-components และวาง URL นี้

https://test.bsru-components.plusdet.com/mcp

Cursor

วางใน ~/.cursor/mcp.json หรือ .cursor/mcp.json ของโปรเจกต์

{
  "mcpServers": {
    "bsru-components": {
      "url": "https://test.bsru-components.plusdet.com/mcp"
    }
  }
}

VS Code with GitHub Copilot

วางใน .vscode/mcp.json ของโปรเจกต์ แล้วเลือก Start ที่ชื่อเซิร์ฟเวอร์

{
  "servers": {
    "bsru-components": {
      "type": "http",
      "url": "https://test.bsru-components.plusdet.com/mcp"
    }
  }
}

OpenAI Codex CLI

วางใน ~/.codex/config.toml

[mcp_servers.bsru-components]
url = "https://test.bsru-components.plusdet.com/mcp"

Gemini CLI

วางใน ~/.gemini/settings.json

{
  "mcpServers": {
    "bsru-components": {
      "httpUrl": "https://test.bsru-components.plusdet.com/mcp"
    }
  }
}

Windsurf

วางใน ~/.codeium/windsurf/mcp_config.json

{
  "mcpServers": {
    "bsru-components": {
      "serverUrl": "https://test.bsru-components.plusdet.com/mcp"
    }
  }
}

Any other tool

เครื่องมือที่เรียกได้แค่เซิร์ฟเวอร์ในเครื่อง ให้ใช้ mcp-remote เป็นตัวเชื่อม ต้องมี Node.js

{
  "mcpServers": {
    "bsru-components": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote@0.16.5",
        "https://test.bsru-components.plusdet.com/mcp"
      ]
    }
  }
}

บอก AI ให้เริ่มจาก get_started

เซิร์ฟเวอร์ส่งคำแนะนำให้เครื่องมือ AI ทุกตัวตอนเชื่อมต่ออยู่แล้ว ถ้าเครื่องมือของคุณไม่อ่าน ให้วางข้อความนี้ในคำสั่งแรก หรือในไฟล์คำแนะนำของโปรเจกต์ เช่น CLAUDE.md หรือ AGENTS.md

Use the bsru-components MCP server. Call get_started first, then get_component (and get_component_css or get_example_markup when you need the look) for every component you use. Build the screen only from @bsru/ui components.

สิ่งที่ AI ถามได้

13 เครื่องมือ อ่านอย่างเดียวทั้งหมด

เครื่องมือของเซิร์ฟเวอร์ MCP
เครื่องมือได้อะไร
get_startedอ่านก่อนเริ่ม: กฎของหน้าจอ วิธีประกอบหน้า และคอมโพเนนต์ทุกตัว
list_componentsคอมโพเนนต์ทุกตัวตามกลุ่ม
get_componentคำอธิบาย ควรใช้เมื่อไร props ทุกตัว ชนิดข้อมูล กฎ ชื่อส่วน และโค้ดตัวอย่าง
get_component_sourceซอร์สโค้ด React ของคอมโพเนนต์
get_source_fileไฟล์ใดก็ได้ใน ui/src รวมถึงไฟล์ช่วยที่วาดบางส่วนของคอมโพเนนต์
get_component_cssCSS ของทุกคลาสที่คอมโพเนนต์ใช้ และ utility ของ Tailwind
get_example_markupHTML ที่ตัวอย่างแสดงจริง พร้อม data-ui และ data-ui-part
searchค้นหาคอมโพเนนต์ props ตัวอย่าง และชนิดข้อมูล ทั้งไทยและอังกฤษ
find_iconsไอคอนของ lucide ที่ส่งให้คอมโพเนนต์ได้ และไอคอนที่คอมโพเนนต์ใช้อยู่แล้ว
get_typeชนิดข้อมูลหรือฟังก์ชันช่วยที่ส่งออก เช่น DataColumn และ money()
get_page_guideหน้าเต็มพร้อมกฎและโค้ด เช่น หน้าเข้าสู่ระบบ และแดชบอร์ด
get_release_notesสิ่งที่เปลี่ยนในแต่ละเวอร์ชัน และสิ่งที่แอปต้องทำ
get_documentเอกสารและสไตล์ชีตทั้งไฟล์ เช่น README.md components.md และ theme.css

เวอร์ชันของเซิร์ฟเวอร์

เซิร์ฟเวอร์อธิบายเวอร์ชันล่าสุดของคลัง เหมือนเว็บนี้ ถ้าแอปปักเวอร์ชันเก่ากว่าใน .components/VERSION ให้ AI เรียก get_release_notes จากเวอร์ชันนั้น เพื่อดูว่ามีอะไรเปลี่ยน