Skip to main content

Browser Proxy

บริการ browser automation — Docker container แยกต่างหากบน port 13000 สำหรับควบคุม headless browser


Browser Proxy

Browser Proxy เป็น Docker service แยกต่างหาก ที่ให้บริการ headless browser automation ผ่าน Playwright โดยไม่ได้เป็นส่วนหนึ่งของ Synapse API โดยตรง — endpoint ของ Synapse ไม่มีพาธ /browser/*

Architecture

┌──────────────┐                ┌──────────────────┐
│  Synapse API │                │  Browser Proxy   │
│  port 12800  │                │  port 13000      │
│              │                │  (Playwright)    │
└──────────────┘                └──────────────────┘
       ▲                                ▲
       │                                │
       └──────────┌─────────────┐──────┘
                  │  MCP Server │
                  │  port 13100 │
                  └─────────────┘

วิธีการเข้าถึง

วิธีที่ 1: ผ่าน Synapse MCP Server (แนะนำ)

Synapse MCP server เปิดเผย browser tools เป็น MCP tools ใช้สำหรับ browser automation ที่ขับเคลื่อนด้วย LLM:

// Claude Desktop config
{
  "mcpServers": {
    "synapse": {
      "command": "npx",
      "args": ["-y", "synapse-mcp-api@latest"],
      "env": {
        "SYNAPSE_MIND_KEY": "mk_...",
        "SYNAPSE_URL": "https://synapse.schaefer.zone"
      }
    }
  }
}

MCP browser tools ที่ใช้ได้:

  • browser_new — เปิด browser tab ใหม่
  • browser_navigate — นำทางไปยัง URL
  • browser_click — คลิกที่ element
  • browser_type — พิมพ์ข้อความลงใน field
  • browser_screenshot — จับภาพ screenshot
  • browser_close — ปิด tab
  • (และอีกมาก — ดู MCP integration)

วิธีที่ 2: เข้าถึง Browser Proxy โดยตรง

สำหรับการผสานรวมที่ไม่ใช่ MCP ให้เชื่อมต่อกับ browser-proxy service โดยตรง:

# Health check
curl http://browser-proxy.schaefer.zone:13000/health

# Open a page
curl -X POST http://browser-proxy.schaefer.zone:13000/navigate \
  -H "Content-Type: application/json" \
  -d '{"url": "https://example.com"}'

กรณีการใช้งานทั่วไป

Web scraping

# Via MCP (Claude Desktop)
"Use browser_navigate to open https://news.ycombinator.com, 
 then extract the top 10 story titles."

Form automation

# Via MCP
"Use browser_navigate to open the login page,
 browser_type to fill username and password,
 browser_click to submit the form."

Screenshot capture

# Via MCP
"Take a screenshot of https://example.com and save it."

Services ที่เกี่ยวข้อง

Service Port วัตถุประสงค์
Synapse API 12800 Memory, chat, tasks
Synapse MCP 13100 MCP server (79 tools)
Browser Proxy 13000 Headless browser automation
SSH Proxy 12900 SSH access to remote machines

ขั้นตอนถัดไป

  • MCP Integration — วิธีใช้ browser tools ผ่าน MCP
  • Computer Control API — สำหรับ GUI automation บนเครื่องที่ลงทะเบียน