antondemidov/screenshot-mcp-server
If you are the rightful owner of screenshot-mcp-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.
MCP Screenshot Server is a reliable Model Context Protocol server designed for taking screenshots with timestamp overlays, supporting multiple platforms and customizable settings.
MCP Screenshot Server - Clean Version
A reliable Model Context Protocol server for taking screenshots with timestamp overlays.
Project Structure
mcp-screenshot-server/
āāā screenshot_server.py # Main server file
āāā config.py # Configuration settings
āāā screenshot_utils.py # Screenshot utilities
āāā requirements.txt # Python dependencies
āāā README.md # This file
Installation
1. Create Project Directory
mkdir mcp-screenshot-server
cd mcp-screenshot-server
2. Create the Files
Create each file with the contents from the artifacts above:
screenshot_server.py
- Main serverconfig.py
- Configurationscreenshot_utils.py
- Utilitiesrequirements.txt
- Dependencies
3. Install Dependencies
# Using your specific Python environment
/Users/antond/.pyenv/versions/3.12.4/envs/python_3_12/bin/pip install -r requirements.txt
4. Test the Server
cd mcp-screenshot-server
/Users/antond/.pyenv/versions/3.12.4/envs/python_3_12/bin/python screenshot_server.py
You should see: "Starting MCP Screenshot Server..." and "Screenshots will be saved to: /Users/antond/Downloads/MCP_Screenshots"
Configuration
Claude Desktop Configuration
Add to your Claude Desktop config file:
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-filesystem",
"/Users/antond/Desktop",
"/Users/antond/Downloads"
]
},
"screenshot": {
"command": "/Users/antond/.pyenv/versions/3.12.4/envs/python_3_12/bin/python",
"args": ["/full/path/to/mcp-screenshot-server/screenshot_server.py"]
}
}
}
Customizing Settings
Edit config.py
to change:
- Screenshots directory path
- Supported image formats
- Default timestamp format
- Font paths for different systems
Features
ā Core Screenshots
- Full screen capture
- Region-based screenshots
- Multiple formats (PNG, JPG, BMP, TIFF)
- Custom filenames with automatic timestamping
ā Timestamp Overlays
- Customizable position (5 locations)
- Font size control (8-72px)
- Color customization
- Semi-transparent backgrounds
- Custom date/time formats
ā File Management
- List all screenshots with metadata
- File size and dimensions info
- Creation/modification timestamps
- Automatic directory organization
ā Cross-Platform
- macOS, Windows, Linux support
- Automatic font detection
- Screen info detection
Usage Examples
Once configured in Claude Desktop:
Basic Screenshots
- "Take a screenshot"
- "Take a screenshot called 'my_desktop'"
- "Take a screenshot in JPG format"
Region Screenshots
- "Take a screenshot of region x=100, y=100, width=800, height=600"
Timestamped Screenshots
- "Take a screenshot with timestamp"
- "Take a screenshot with timestamp in top-right corner"
- "Take a screenshot with large timestamp"
File Management
- "List all my screenshots"
- "Show screen information"
Troubleshooting
Permission Issues (macOS)
Grant screen recording permissions:
- System Preferences ā Security & Privacy ā Screen Recording
- Add Claude Desktop to allowed apps
- Restart Claude Desktop
Import Errors
# Ensure all dependencies are installed
/Users/antond/.pyenv/versions/3.12.4/envs/python_3_12/bin/pip install --upgrade -r requirements.txt
Path Issues
- Use absolute paths in Claude Desktop configuration
- Verify Python executable path with:
which python
- Check file permissions in project directory
Architecture Benefits
šļø Clean Separation
screenshot_server.py
: MCP server handlingconfig.py
: All settings in one placescreenshot_utils.py
: Core screenshot logic
š§ Easy Maintenance
- Modular design for easy updates
- Clear error handling and logging
- Configurable without code changes
š Reliable Performance
- No external browser dependencies
- Uses proven pyautogui library
- Robust error handling
š¦ Simple Deployment
- Minimal dependencies
- Self-contained project
- Easy to backup and share
This clean, modular approach gives you a solid foundation for reliable screenshot functionality that's easy to maintain and extend!