Skip to main content
Glama
Daytona Playwright MCP Server

Daytona Playwright MCP Server

by jamesmurdza

Daytona Playwright MCP 서버

Daytona 클라우드 샌드박스 내부에서 실행되는 스텔스 patchright+Chrome 브라우저를 제어할 수 있는 MCP(Model Context Protocol) 서버입니다. Claude Code, Claude Desktop 또는 MCP 호환 클라이언트와 함께 사용하여 웹을 탐색하고, 스크린샷을 찍고, 양식을 작성하는 등의 작업을 수행하세요.

https://github.com/user-attachments/assets/23b13e1f-4ed3-4204-ad0d-b2fdb1f77d0d

기능

  • 스텔스 Chrome: 가상 디스플레이로 렌더링되는 실제 Chrome(patchright의 스텔스 패치 사용, 헤드리스 아님)

  • 라이브 VNC 보기: browser_start가 반환하는 서명된 미리보기 URL은 샌드박스 데스크톱을 스트리밍하므로 Claude가 무엇을 하고 있는지 확인할 수 있습니다.

  • 클라우드 샌드박스: 브라우저가 로컬 머신과 격리된 Daytona 샌드박스에서 안전하게 실행됩니다.

  • 풍부한 도구 세트: 탐색, 클릭, 입력, 스크롤, 스크린샷 캡처, 콘텐츠 추출, 탭 관리

  • 스크린샷 지원: Claude가 보고 분석할 수 있는 이미지로 스크린샷을 반환합니다.

  • 다중 전송: stdio(기본값), SSE 또는 HTTP와 함께 작동합니다.

Related MCP server: Glance

빠른 시작

1. 패키지 설치

pipx install git+https://github.com/jamesmurdza/playwright-daytona-mcp-server.git

2. Daytona API 키 받기

  1. daytona.io에서 가입하세요.

  2. 대시보드로 이동하여 API 키를 생성하세요.

3. Claude Code / Claude Desktop 구성

MCP 설정에 추가하세요:

{
  "mcpServers": {
    "daytona-playwright": {
      "command": "daytona-playwright-mcp",
      "env": {
        "DAYTONA_API_KEY": "your-api-key-here"
      }
    }
  }
}

사용법

구성이 완료되면 Claude에게 웹 탐색을 요청할 수 있습니다:

"Start a browser and go to https://news.ycombinator.com"

"Take a screenshot of the page"

"Click on the first article link"

"Search for 'AI news' on Google and show me the results"

"Fill out the contact form on example.com with test data"

워크플로우

  1. 브라우저 시작: Claude가 browser_start를 호출하여 Daytona 샌드박스를 생성하고 Chrome을 실행합니다.

  2. 탐색 및 상호 작용: 탐색, 클릭, 입력 및 기타 도구를 사용합니다.

  3. 스크린샷 찍기: browser_screenshot으로 페이지 내용을 확인합니다.

  4. 정리: 완료되면 browser_stop을 호출하여 샌드박스를 삭제합니다.

사용 가능한 도구

브라우저 수명 주기

도구

설명

browser_start

Daytona 샌드박스에서 새 브라우저 세션 시작

browser_stop

브라우저를 중지하고 샌드박스 정리

browser_status

브라우저 실행 여부 확인

탐색

도구

설명

browser_navigate

URL로 이동

browser_back

기록에서 뒤로 이동

browser_forward

기록에서 앞으로 이동

browser_refresh

현재 페이지 새로 고침

상호 작용

도구

설명

browser_click

요소 클릭 (CSS, XPath 또는 텍스트 선택기)

browser_type

입력 필드에 텍스트 입력

browser_press

키보드 키 누르기 (Enter, Tab 등)

browser_hover

요소 위에 마우스 올리기

browser_select

드롭다운에서 선택

browser_scroll

페이지 또는 요소 스크롤

콘텐츠 추출

도구

설명

browser_screenshot

스크린샷 찍기 (전체 페이지 또는 요소)

browser_get_text

페이지에서 텍스트 콘텐츠 가져오기

browser_get_html

HTML 콘텐츠 가져오기

browser_get_attribute

요소의 속성 가져오기

browser_evaluate

JavaScript 실행 및 결과 가져오기

대기

도구

설명

browser_wait_for_selector

요소가 나타나거나 사라질 때까지 대기

browser_wait_for_navigation

탐색이 완료될 때까지 대기

탭 관리

도구

설명

browser_new_tab

새 탭 열기

browser_list_tabs

열려 있는 모든 탭 나열

browser_switch_tab

다른 탭으로 전환

browser_close_tab

탭 닫기

파일 작업

도구

설명

browser_upload_file

파일 입력에 파일 업로드

다른 전송 방식으로 실행

Stdio (기본값 - Claude Code/Desktop용)

daytona-playwright-mcp

HTTP 전송 (원격 연결용)

daytona-playwright-mcp --transport http --host 0.0.0.0 --port 8765

그런 다음 다음을 통해 연결하세요: http://localhost:8765/mcp

SSE 전송 (레거시)

daytona-playwright-mcp --transport sse --host 0.0.0.0 --port 8765

환경 변수

변수

설명

기본값

DAYTONA_API_KEY

Daytona API 키 (필수)

-

DAYTONA_API_URL

Daytona API 서버 URL

https://app.daytona.io/api

개발

소스에서 실행

# Clone the repository
git clone https://github.com/jamesmurdza/playwright-daytona-mcp-server.git
cd playwright-daytona-mcp-server

# Install dependencies
uv sync

# Run the server
uv run daytona-playwright-mcp

개발을 위한 MCP 구성

로컬에서 개발할 때는 다음 MCP 구성을 사용하세요:

{
  "mcpServers": {
    "daytona-playwright": {
      "command": "uv",
      "args": ["run", "--directory", "/path/to/playwright-daytona-mcp-server", "daytona-playwright-mcp"],
      "env": {
        "DAYTONA_API_KEY": "your-api-key-here"
      }
    }
  }
}

테스트 실행

uv run pytest

작동 원리

  1. browser_start를 호출하면 서버는 다음을 수행합니다:

    • 최소한의 Daytona 샌드박스 이미지를 선언적으로 빌드합니다 (xfce + computer_use용 VNC 스택, Chrome 채널이 포함된 patchright).

    • computer_use를 시작하여 샌드박스 데스크톱이 6080 포트에서 스트리밍되도록 합니다 (반환된 "라이브 보기" URL).

    • 실행 시점에 patchright의 스텔스 패치가 적용된 상태로 DISPLAY=:0에서 CDP가 0.0.0.0:9222에 바인딩된 Chrome을 실행합니다 (TCP 프록시 불필요).

    • Daytona의 보안 미리보기 URL을 통해 서명된 CDP WebSocket으로 Chrome에 연결합니다.

  2. 모든 브라우저 명령은 원격 브라우저에 연결된 비동기 Playwright API를 통해 실행됩니다.

  3. 스크린샷은 PNG 이미지로 캡처되어 MCP의 이미지 콘텐츠 유형을 통해 반환됩니다.

  4. browser_stop을 호출하면 샌드박스가 삭제되고 모든 리소스가 해제됩니다.

크레딧

Available Tools

26 tools
browser_backB

Navigate back in browser history.

Inputs: no named parameters. Returns: result

browser_clickA

Click on an element on the page.

Supports CSS selectors, XPath, and text selectors. Examples:

  • CSS: "button.primary", "#submit-btn", "[data-testid='login']"

  • XPath: "//button[@type='submit']"

  • Text: "text=Sign In", "text=Submit"

Inputs: selector (required), button, click_count, timeout. Returns: result

browser_close_tabB

Close a browser tab.

Inputs: index. Returns: result

browser_download_waitA

Wait for a download to start and complete, returning the downloaded file path.

Call this before triggering the download action.

Inputs: timeout. Returns: result

browser_evaluateA

Execute JavaScript in the page context and return the result.

Examples:

  • "document.title"

  • "window.location.href"

  • "document.querySelectorAll('a').length"

  • "JSON.stringify(localStorage)"

Inputs: script (required). Returns: result

browser_forwardB

Navigate forward in browser history.

Inputs: no named parameters. Returns: result

browser_get_attributeB

Get an attribute value from an element.

Inputs: selector (required), attribute (required), timeout. Returns: result

browser_get_htmlB

Get HTML content from the page or a specific element.

Inputs: selector, outer. Returns: result

browser_get_textB

Get text content from the page or specific elements.

Inputs: selector, timeout. Returns: result

browser_hoverB

Hover over an element on the page.

Inputs: selector (required), timeout. Returns: result

browser_list_tabsA

List all open tabs with their URLs and titles.

Inputs: no named parameters. Returns: result

browser_navigateB

Navigate the browser to a URL.

Inputs: url (required), wait_until. Returns: result

browser_new_tabA

Open a new browser tab and switch to it.

Inputs: url. Returns: result

browser_pressB

Press a keyboard key, optionally on a specific element.

Key examples: Enter, Tab, Escape, Backspace, Delete, ArrowUp, ArrowDown, Control+a, Control+c, Control+v, Shift+Tab, Alt+F4

Inputs: key (required), selector, timeout. Returns: result

browser_refreshB

Refresh the current page.

Inputs: no named parameters. Returns: result

browser_screenshotC

Take a screenshot of the current page or a specific element.

Returns the screenshot as an image that can be displayed.

Inputs: full_page, selector.

browser_scrollB

Scroll the page or a specific element.

Inputs: direction, amount, selector. Returns: result

browser_selectA

Select an option from a dropdown ( element).

Provide one of: value, label, or index.

Inputs: selector (required), value, label, index, +1 more. Returns: result

browser_startA

Start a new browser session in a Daytona sandbox.

This creates a cloud sandbox with Chrome installed, launches the browser, and establishes a connection for remote control. Must be called before using any other browser tools.

Inputs: timeout. Returns: result

browser_statusB

Check the current status of the browser session.

Inputs: no named parameters. Returns: result

browser_stopA

Stop the browser and clean up the Daytona sandbox.

Call this when you're done using the browser to free up resources.

Inputs: no named parameters. Returns: result

browser_switch_tabB

Switch to a different browser tab by index.

Inputs: index (required). Returns: result

browser_typeB

Type text into an input field or editable element.

Inputs: selector (required), text (required), clear_first, delay, +1 more. Returns: result

browser_upload_fileB

Upload a file to a file input element.

Note: The file must exist on the machine running this MCP server.

Inputs: selector (required), file_path (required), timeout. Returns: result

browser_wait_for_navigationB

Wait for a navigation to complete.

Inputs: url, timeout. Returns: result

browser_wait_for_selectorB

Wait for an element to reach a specific state.

States:

  • attached: Element is in the DOM

  • detached: Element is removed from the DOM

  • visible: Element is visible on the page

  • hidden: Element is hidden or removed

Inputs: selector (required), state, timeout. Returns: result

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.6/5.0

    Scored across 26 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose with no ambiguity. For example, browser_click is for clicking, browser_type is for typing, browser_screenshot is for capturing images, and browser_wait_for_selector is for waiting on element states. The descriptions reinforce these distinctions, making misselection unlikely.

    Naming Consistency5/5

    All tools follow a consistent 'browser_verb' or 'browser_verb_noun' naming pattern (e.g., browser_back, browser_click, browser_screenshot). This uniformity makes the tool set predictable and easy to navigate, with no deviations in style or convention.

    Tool Count3/5

    With 26 tools, the count feels heavy for a browser automation server, though not extreme. While it covers many operations, some tools could potentially be consolidated (e.g., browser_back and browser_forward are simple navigations), making the set borderline in scope.

    Completeness5/5

    The tool set provides complete coverage for browser automation, including session management (start, stop, status), navigation, interaction (click, type, hover), inspection (get_html, get_text), and utilities (screenshot, download). There are no obvious gaps, and agents can handle typical workflows without dead ends.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      D
      maintenance
      An MCP server that provides AI models with full browser automation capabilities through Chrome. It enables navigation, interaction, screenshots, and complete DevTools access by bridging AI clients with a companion Chrome extension.
      99
      11 npm
      3
      Apache 2.0
    • A
      license
      Not graded
      quality
      D
      maintenance
      MCP server to control Chrome browsers locally or remotely via the Claude extension, enabling navigation, form filling, screenshots, and JavaScript execution from any MCP client.
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Local browser automation MCP server for Claude Code, enabling navigation, clicking, typing, and inspecting real web pages via Google Chrome.
      1
      MIT