🚨 Latest Research:Tanstack npm Packages Compromised in Ongoing Mini Shai-Hulud Supply-Chain Attack.Learn More →
Socket
Book a DemoSign in
Socket

@dwmkerr/shellwright-mcp-server

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@dwmkerr/shellwright-mcp-server

Playwright for the shell - MCP server for terminal recording and automation

latest
Source
npmnpm
Version
0.1.2
Version published
Maintainers
1
Created
Source

🖥️ shellwright

Playwright for the shell. AI-driven terminal automation, screenshots and video recording.

Finally. Your AI agents can close Vim

User: Open Vim. Tell me how to close it. Close it. Record this as a video.

Shellwright Demo

Quickstart | Examples | MCP Tools | Configuration

cicd npm version

Quickstart

Configure your LLM, IDE or whatever to use the Shellwright MCP server:

{
  "mcpServers": {
    "shellwright": {
      "command": "npx",
      "args": ["-y", "shellwright-mcp-server"]
    }
  }
}

Running Locally

Run the MCP server:

npm install
npm run dev

The server runs at http://localhost:7498/mcp.

Testing with the MCP Inspector

Open the MCP Inspector in another terminal and connect to http://localhost:7498/mcp to list and test tools:

# Open MCP inspector in another terminal.
npx @modelcontextprotocol/inspector

# Now connect to:
# http://localhost:7498/mcp

Testing with an Agent

Run the demo.py program to chat to an agent that has the Shellwright tool:

# Optionally setup your .env to specify configuration.
# cp ./demo/.env.sample .env && vi .env

# Install requirements and run the agent.
pip install -r ./demo/requirements.txt
python ./demo/demo.py

# Output:
# User (enter message): Show me what the htop tool looks like showing me my resources.

# ...or provide a message directly.
python ./demo/demo.py -- "Run a shell command to show me the names \
of the folders in this directory and take a screenshot and give me its path"

You will see logs from the MCP server and the demo agent:

Screenshot of the MCP server and demo agent

Screenshots and videos by default will be written to ./output.

Examples

Have fun with some prompts:

Open Vim. Write a message saying how to close Vim. Close Vim. Give me a screenshot of each step and a GIF recording.

MCP Tools

ToolDescription
shell_startStart a new PTY session
shell_sendSend input to a session
shell_readRead the terminal buffer
shell_snapshotGet terminal screen as text grid
shell_screenshotSave terminal state to txt, svg, png
shell_record_startStart recording for GIF export
shell_record_stopStop recording and export GIF
shell_stopStop a PTY session

Configuration

VariableParameterDefaultDescription
PORT--port, -p7498Server port ("SWRT" on a phone keypad)
THEME--theme, -tone-darkColor theme (one-dark, one-light, dracula, solarized-dark, nord)
TEMP_DIR--temp-dir/tmp/shellwrightDirectory for recording frames

TODO

  • Video export (MP4/MOV) via ffmpeg
  • Set screen size tool
  • Better logging

License

MIT

Keywords

mcp

FAQs

Package last updated on 16 Dec 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts