Screenshot
clawhub2 platformsScreen Capture Very Easy
3.7
Capture, inspect, and compare screenshots of screens, windows, regions, web pages, simulators, and CI runs with the right tool, wait strategy, viewport, and...
1.2K
clawhub install screenshotCapture desktop screenshots from Windows system
# Install Skill (downloads SKILL.md to .claude/skills/) clawhub install windows-screenshot # Then just tell Claude: "use Windows Screenshot to help me..."
# Same install command — works with all SKILL.md-compatible AI coding tools clawhub install windows-screenshot
This Skill is compatible with the OpenClaw standard. After installation, a SKILL.md file is auto-generated, usable by any OpenClaw-compatible AI Agent (Claude Code, Cursor, Windsurf, etc.).
screenshot.txt(PowerShell 脚本内容)。使用时:
screenshot.txt 复制或重命名为 screenshot.ps1powershell -File screenshot.ps1OPENCLAW_MEDIA_DIR - 自定义输出目录$USERPROFILE\.openclaw\media
- 脚本会自动创建此目录
#### 设置环境变量示例
PowerShell:
``powershell
$env:OPENCLAW_MEDIA_DIR = "C:\MyScreenshots"
powershell -File screenshot.ps1
`
Command Prompt:
`cmd
set OPENCLAW_MEDIA_DIR=C:\MyScreenshots
PowerShell -File screenshot.ps1
`
使用方法
方法 1:直接执行
`powershell
powershell -File screenshot.ps1
`
输出:
`
MEDIA:C:\Users\YourUsername\.openclaw\media\screenshot_YYYYMMDD_HHMMSS.png
`
方法 2:通过 OpenClaw
`bash
openclaw exec powershell -File screenshot.ps1
`
方法 3:发送到 Telegram(需要配置环境变量)
`bash
# 步骤 1:捕获截图
openclaw exec powershell -File screenshot.ps1
# 步骤 2:发送(需要 TELEGRAM_BOT_TOKEN 和用户 ID)
openclaw message send --channel telegram --target YOUR_USER_ID --media /path/to/screenshot.png
`
输出
脚本将截图保存为 PNG:
`
.openclaw/media/screenshot_YYYYMMDD_HHMMSS.png
`
并输出 MEDIA: 前缀路径用于后续处理。
技术细节
| 属性 | 值 |
|------|-----|
| 图像库 | System.Drawing (GDI+) |
| 格式 | PNG 24-bit |
| 分辨率 | 自适应(根据屏幕缩放) |
| 文件大小 | 通常 50-200 KB |
| 依赖 | .NET Framework 4.x+(Windows 内置) |
故障排查
| 问题 | 解决方案 |
|------|---------|
| "找不到类型 System.Drawing" | 在 .NET Framework 4.x+ 上运行(Windows 默认) |
| 图像全黑 | 检查屏幕/GPU 状态;确保不在锁屏 |
| 文件名冲突 | 脚本使用时间戳自动避免重复 |
许可
MIT-0 - 无署名、无限制使用、修改和分发。
---
安全声明
✅ 所有代码都是开源的且经过审查
- 脚本功能:捕获屏幕内容到 PNG 文件
- 数据处理:仅保存到本地
.openclaw/media` 目录
clawhub run windows-screenshot --output screenshot_$(date +%Y%m%d_%H%M%S).png --format png --quality 95Capture, inspect, and compare screenshots of screens, windows, regions, web pages, simulators, and CI runs with the right tool, wait strategy, viewport, and...
clawhub install screenshot