{
  "schemaVersion": "1.0",
  "item": {
    "slug": "desktop-control-1-0-0",
    "name": "Desktop Control 1.0.0",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/wpegley/desktop-control-1-0-0",
    "canonicalUrl": "https://clawhub.ai/wpegley/desktop-control-1-0-0",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/desktop-control-1-0-0",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=desktop-control-1-0-0",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "ai_agent.py",
      "AI_AGENT_GUIDE.md",
      "demo.py",
      "QUICK_REFERENCE.md",
      "SKILL.md",
      "_meta.json"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-04-30T16:55:25.780Z",
      "expiresAt": "2026-05-07T16:55:25.780Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
        "contentDisposition": "attachment; filename=\"network-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null
      },
      "scope": "source",
      "summary": "Source download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this source.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/desktop-control-1-0-0"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/desktop-control-1-0-0",
    "agentPageUrl": "https://openagent3.xyz/skills/desktop-control-1-0-0/agent",
    "manifestUrl": "https://openagent3.xyz/skills/desktop-control-1-0-0/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/desktop-control-1-0-0/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "Desktop Control Skill",
        "body": "The most advanced desktop automation skill for OpenClaw. Provides pixel-perfect mouse control, lightning-fast keyboard input, screen capture, window management, and clipboard operations."
      },
      {
        "title": "Mouse Control",
        "body": "✅ Absolute positioning - Move to exact coordinates\n✅ Relative movement - Move from current position\n✅ Smooth movement - Natural, human-like mouse paths\n✅ Click types - Left, right, middle, double, triple clicks\n✅ Drag & drop - Drag from point A to point B\n✅ Scroll - Vertical and horizontal scrolling\n✅ Position tracking - Get current mouse coordinates"
      },
      {
        "title": "Keyboard Control",
        "body": "✅ Text typing - Fast, accurate text input\n✅ Hotkeys - Execute keyboard shortcuts (Ctrl+C, Win+R, etc.)\n✅ Special keys - Enter, Tab, Escape, Arrow keys, F-keys\n✅ Key combinations - Multi-key press combinations\n✅ Hold & release - Manual key state control\n✅ Typing speed - Configurable WPM (instant to human-like)"
      },
      {
        "title": "Screen Operations",
        "body": "✅ Screenshot - Capture entire screen or regions\n✅ Image recognition - Find elements on screen (via OpenCV)\n✅ Color detection - Get pixel colors at coordinates\n✅ Multi-monitor - Support for multiple displays"
      },
      {
        "title": "Window Management",
        "body": "✅ Window list - Get all open windows\n✅ Activate window - Bring window to front\n✅ Window info - Get position, size, title\n✅ Minimize/Maximize - Control window states"
      },
      {
        "title": "Safety Features",
        "body": "✅ Failsafe - Move mouse to corner to abort\n✅ Pause control - Emergency stop mechanism\n✅ Approval mode - Require confirmation for actions\n✅ Bounds checking - Prevent out-of-screen operations\n✅ Logging - Track all automation actions"
      },
      {
        "title": "Installation",
        "body": "First, install required dependencies:\n\npip install pyautogui pillow opencv-python pygetwindow"
      },
      {
        "title": "Basic Usage",
        "body": "from skills.desktop_control import DesktopController\n\n# Initialize controller\ndc = DesktopController(failsafe=True)\n\n# Mouse operations\ndc.move_mouse(500, 300)  # Move to coordinates\ndc.click()  # Left click at current position\ndc.click(100, 200, button=\"right\")  # Right click at position\n\n# Keyboard operations\ndc.type_text(\"Hello from OpenClaw!\")\ndc.hotkey(\"ctrl\", \"c\")  # Copy\ndc.press(\"enter\")\n\n# Screen operations\nscreenshot = dc.screenshot()\nposition = dc.get_mouse_position()"
      },
      {
        "title": "Mouse Functions",
        "body": "move_mouse(x, y, duration=0, smooth=True)\n\nMove mouse to absolute screen coordinates.\n\nParameters:\n\nx (int): X coordinate (pixels from left)\ny (int): Y coordinate (pixels from top)\nduration (float): Movement time in seconds (0 = instant, 0.5 = smooth)\nsmooth (bool): Use bezier curve for natural movement\n\nExample:\n\n# Instant movement\ndc.move_mouse(1000, 500)\n\n# Smooth 1-second movement\ndc.move_mouse(1000, 500, duration=1.0)\n\nmove_relative(x_offset, y_offset, duration=0)\n\nMove mouse relative to current position.\n\nParameters:\n\nx_offset (int): Pixels to move horizontally (positive = right)\ny_offset (int): Pixels to move vertically (positive = down)\nduration (float): Movement time in seconds\n\nExample:\n\n# Move 100px right, 50px down\ndc.move_relative(100, 50, duration=0.3)\n\nclick(x=None, y=None, button='left', clicks=1, interval=0.1)\n\nPerform mouse click.\n\nParameters:\n\nx, y (int, optional): Coordinates to click (None = current position)\nbutton (str): 'left', 'right', 'middle'\nclicks (int): Number of clicks (1 = single, 2 = double)\ninterval (float): Delay between multiple clicks\n\nExample:\n\n# Simple left click\ndc.click()\n\n# Double-click at specific position\ndc.click(500, 300, clicks=2)\n\n# Right-click\ndc.click(button='right')\n\ndrag(start_x, start_y, end_x, end_y, duration=0.5, button='left')\n\nDrag and drop operation.\n\nParameters:\n\nstart_x, start_y (int): Starting coordinates\nend_x, end_y (int): Ending coordinates\nduration (float): Drag duration\nbutton (str): Mouse button to use\n\nExample:\n\n# Drag file from desktop to folder\ndc.drag(100, 100, 500, 500, duration=1.0)\n\nscroll(clicks, direction='vertical', x=None, y=None)\n\nScroll mouse wheel.\n\nParameters:\n\nclicks (int): Scroll amount (positive = up/left, negative = down/right)\ndirection (str): 'vertical' or 'horizontal'\nx, y (int, optional): Position to scroll at\n\nExample:\n\n# Scroll down 5 clicks\ndc.scroll(-5)\n\n# Scroll up 10 clicks\ndc.scroll(10)\n\n# Horizontal scroll\ndc.scroll(5, direction='horizontal')\n\nget_mouse_position()\n\nGet current mouse coordinates.\n\nReturns: (x, y) tuple\n\nExample:\n\nx, y = dc.get_mouse_position()\nprint(f\"Mouse is at: {x}, {y}\")"
      },
      {
        "title": "Keyboard Functions",
        "body": "type_text(text, interval=0, wpm=None)\n\nType text with configurable speed.\n\nParameters:\n\ntext (str): Text to type\ninterval (float): Delay between keystrokes (0 = instant)\nwpm (int, optional): Words per minute (overrides interval)\n\nExample:\n\n# Instant typing\ndc.type_text(\"Hello World\")\n\n# Human-like typing at 60 WPM\ndc.type_text(\"Hello World\", wpm=60)\n\n# Slow typing with 0.1s between keys\ndc.type_text(\"Hello World\", interval=0.1)\n\npress(key, presses=1, interval=0.1)\n\nPress and release a key.\n\nParameters:\n\nkey (str): Key name (see Key Names section)\npresses (int): Number of times to press\ninterval (float): Delay between presses\n\nExample:\n\n# Press Enter\ndc.press('enter')\n\n# Press Space 3 times\ndc.press('space', presses=3)\n\n# Press Down arrow\ndc.press('down')\n\nhotkey(*keys, interval=0.05)\n\nExecute keyboard shortcut.\n\nParameters:\n\n*keys (str): Keys to press together\ninterval (float): Delay between key presses\n\nExample:\n\n# Copy (Ctrl+C)\ndc.hotkey('ctrl', 'c')\n\n# Paste (Ctrl+V)\ndc.hotkey('ctrl', 'v')\n\n# Open Run dialog (Win+R)\ndc.hotkey('win', 'r')\n\n# Save (Ctrl+S)\ndc.hotkey('ctrl', 's')\n\n# Select All (Ctrl+A)\ndc.hotkey('ctrl', 'a')\n\nkey_down(key) / key_up(key)\n\nManually control key state.\n\nExample:\n\n# Hold Shift\ndc.key_down('shift')\ndc.type_text(\"hello\")  # Types \"HELLO\"\ndc.key_up('shift')\n\n# Hold Ctrl and click (for multi-select)\ndc.key_down('ctrl')\ndc.click(100, 100)\ndc.click(200, 100)\ndc.key_up('ctrl')"
      },
      {
        "title": "Screen Functions",
        "body": "screenshot(region=None, filename=None)\n\nCapture screen or region.\n\nParameters:\n\nregion (tuple, optional): (left, top, width, height) for partial capture\nfilename (str, optional): Path to save image\n\nReturns: PIL Image object\n\nExample:\n\n# Full screen\nimg = dc.screenshot()\n\n# Save to file\ndc.screenshot(filename=\"screenshot.png\")\n\n# Capture specific region\nimg = dc.screenshot(region=(100, 100, 500, 300))\n\nget_pixel_color(x, y)\n\nGet color of pixel at coordinates.\n\nReturns: RGB tuple (r, g, b)\n\nExample:\n\nr, g, b = dc.get_pixel_color(500, 300)\nprint(f\"Color at (500, 300): RGB({r}, {g}, {b})\")\n\nfind_on_screen(image_path, confidence=0.8)\n\nFind image on screen (requires OpenCV).\n\nParameters:\n\nimage_path (str): Path to template image\nconfidence (float): Match threshold (0-1)\n\nReturns: (x, y, width, height) or None\n\nExample:\n\n# Find button on screen\nlocation = dc.find_on_screen(\"button.png\")\nif location:\n    x, y, w, h = location\n    # Click center of found image\n    dc.click(x + w//2, y + h//2)\n\nget_screen_size()\n\nGet screen resolution.\n\nReturns: (width, height) tuple\n\nExample:\n\nwidth, height = dc.get_screen_size()\nprint(f\"Screen: {width}x{height}\")"
      },
      {
        "title": "Window Functions",
        "body": "get_all_windows()\n\nList all open windows.\n\nReturns: List of window titles\n\nExample:\n\nwindows = dc.get_all_windows()\nfor title in windows:\n    print(f\"Window: {title}\")\n\nactivate_window(title_substring)\n\nBring window to front by title.\n\nParameters:\n\ntitle_substring (str): Part of window title to match\n\nExample:\n\n# Activate Chrome\ndc.activate_window(\"Chrome\")\n\n# Activate VS Code\ndc.activate_window(\"Visual Studio Code\")\n\nget_active_window()\n\nGet currently focused window.\n\nReturns: Window title (str)\n\nExample:\n\nactive = dc.get_active_window()\nprint(f\"Active window: {active}\")"
      },
      {
        "title": "Clipboard Functions",
        "body": "copy_to_clipboard(text)\n\nCopy text to clipboard.\n\nExample:\n\ndc.copy_to_clipboard(\"Hello from OpenClaw!\")\n\nget_from_clipboard()\n\nGet text from clipboard.\n\nReturns: str\n\nExample:\n\ntext = dc.get_from_clipboard()\nprint(f\"Clipboard: {text}\")"
      },
      {
        "title": "Alphabet Keys",
        "body": "'a' through 'z'"
      },
      {
        "title": "Number Keys",
        "body": "'0' through '9'"
      },
      {
        "title": "Function Keys",
        "body": "'f1' through 'f24'"
      },
      {
        "title": "Special Keys",
        "body": "'enter' / 'return'\n'esc' / 'escape'\n'space' / 'spacebar'\n'tab'\n'backspace'\n'delete' / 'del'\n'insert'\n'home'\n'end'\n'pageup' / 'pgup'\n'pagedown' / 'pgdn'"
      },
      {
        "title": "Arrow Keys",
        "body": "'up' / 'down' / 'left' / 'right'"
      },
      {
        "title": "Modifier Keys",
        "body": "'ctrl' / 'control'\n'shift'\n'alt'\n'win' / 'winleft' / 'winright'\n'cmd' / 'command' (Mac)"
      },
      {
        "title": "Lock Keys",
        "body": "'capslock'\n'numlock'\n'scrolllock'"
      },
      {
        "title": "Punctuation",
        "body": "'.' / ',' / '?' / '!' / ';' / ':'\n'[' / ']' / '{' / '}'\n'(' / ')'\n'+' / '-' / '*' / '/' / '='"
      },
      {
        "title": "Failsafe Mode",
        "body": "Move mouse to any corner of the screen to abort all automation.\n\n# Enable failsafe (enabled by default)\ndc = DesktopController(failsafe=True)"
      },
      {
        "title": "Pause Control",
        "body": "# Pause all automation for 2 seconds\ndc.pause(2.0)\n\n# Check if automation is safe to proceed\nif dc.is_safe():\n    dc.click(500, 500)"
      },
      {
        "title": "Approval Mode",
        "body": "Require user confirmation before actions:\n\ndc = DesktopController(require_approval=True)\n\n# This will ask for confirmation\ndc.click(500, 500)  # Prompt: \"Allow click at (500, 500)? [y/n]\""
      },
      {
        "title": "Example 1: Automated Form Filling",
        "body": "dc = DesktopController()\n\n# Click name field\ndc.click(300, 200)\ndc.type_text(\"John Doe\", wpm=80)\n\n# Tab to next field\ndc.press('tab')\ndc.type_text(\"john@example.com\", wpm=80)\n\n# Tab to password\ndc.press('tab')\ndc.type_text(\"SecurePassword123\", wpm=60)\n\n# Submit form\ndc.press('enter')"
      },
      {
        "title": "Example 2: Screenshot Region and Save",
        "body": "# Capture specific area\nregion = (100, 100, 800, 600)  # left, top, width, height\nimg = dc.screenshot(region=region)\n\n# Save with timestamp\nimport datetime\ntimestamp = datetime.datetime.now().strftime(\"%Y%m%d_%H%M%S\")\nimg.save(f\"capture_{timestamp}.png\")"
      },
      {
        "title": "Example 3: Multi-File Selection",
        "body": "# Hold Ctrl and click multiple files\ndc.key_down('ctrl')\ndc.click(100, 200)  # First file\ndc.click(100, 250)  # Second file\ndc.click(100, 300)  # Third file\ndc.key_up('ctrl')\n\n# Copy selected files\ndc.hotkey('ctrl', 'c')"
      },
      {
        "title": "Example 4: Window Automation",
        "body": "# Activate Calculator\ndc.activate_window(\"Calculator\")\ntime.sleep(0.5)\n\n# Type calculation\ndc.type_text(\"5+3=\", interval=0.2)\ntime.sleep(0.5)\n\n# Take screenshot of result\ndc.screenshot(filename=\"calculation_result.png\")"
      },
      {
        "title": "Example 5: Drag & Drop File",
        "body": "# Drag file from source to destination\ndc.drag(\n    start_x=200, start_y=300,  # File location\n    end_x=800, end_y=500,       # Folder location\n    duration=1.0                 # Smooth 1-second drag\n)"
      },
      {
        "title": "⚡ Performance Tips",
        "body": "Use instant movements for speed: duration=0\nBatch operations instead of individual calls\nCache screen positions instead of recalculating\nDisable failsafe for maximum performance (use with caution)\nUse hotkeys instead of menu navigation"
      },
      {
        "title": "⚠️ Important Notes",
        "body": "Screen coordinates start at (0, 0) in top-left corner\nMulti-monitor setups may have negative coordinates for secondary displays\nWindows DPI scaling may affect coordinate accuracy\nFailsafe corners are: (0,0), (width-1, 0), (0, height-1), (width-1, height-1)\nSome applications may block simulated input (games, secure apps)"
      },
      {
        "title": "Mouse not moving to correct position",
        "body": "Check DPI scaling settings\nVerify screen resolution matches expectations\nUse get_screen_size() to confirm dimensions"
      },
      {
        "title": "Keyboard input not working",
        "body": "Ensure target application has focus\nSome apps require admin privileges\nTry increasing interval for reliability"
      },
      {
        "title": "Failsafe triggering accidentally",
        "body": "Increase screen border tolerance\nMove mouse away from corners during normal use\nDisable if needed: DesktopController(failsafe=False)"
      },
      {
        "title": "Permission errors",
        "body": "Run Python with administrator privileges for some operations\nSome secure applications block automation"
      },
      {
        "title": "📦 Dependencies",
        "body": "PyAutoGUI - Core automation engine\nPillow - Image processing\nOpenCV (optional) - Image recognition\nPyGetWindow - Window management\n\nInstall all:\n\npip install pyautogui pillow opencv-python pygetwindow\n\nBuilt for OpenClaw - The ultimate desktop automation companion 🦞"
      }
    ],
    "body": "Desktop Control Skill\n\nThe most advanced desktop automation skill for OpenClaw. Provides pixel-perfect mouse control, lightning-fast keyboard input, screen capture, window management, and clipboard operations.\n\n🎯 Features\nMouse Control\n✅ Absolute positioning - Move to exact coordinates\n✅ Relative movement - Move from current position\n✅ Smooth movement - Natural, human-like mouse paths\n✅ Click types - Left, right, middle, double, triple clicks\n✅ Drag & drop - Drag from point A to point B\n✅ Scroll - Vertical and horizontal scrolling\n✅ Position tracking - Get current mouse coordinates\nKeyboard Control\n✅ Text typing - Fast, accurate text input\n✅ Hotkeys - Execute keyboard shortcuts (Ctrl+C, Win+R, etc.)\n✅ Special keys - Enter, Tab, Escape, Arrow keys, F-keys\n✅ Key combinations - Multi-key press combinations\n✅ Hold & release - Manual key state control\n✅ Typing speed - Configurable WPM (instant to human-like)\nScreen Operations\n✅ Screenshot - Capture entire screen or regions\n✅ Image recognition - Find elements on screen (via OpenCV)\n✅ Color detection - Get pixel colors at coordinates\n✅ Multi-monitor - Support for multiple displays\nWindow Management\n✅ Window list - Get all open windows\n✅ Activate window - Bring window to front\n✅ Window info - Get position, size, title\n✅ Minimize/Maximize - Control window states\nSafety Features\n✅ Failsafe - Move mouse to corner to abort\n✅ Pause control - Emergency stop mechanism\n✅ Approval mode - Require confirmation for actions\n✅ Bounds checking - Prevent out-of-screen operations\n✅ Logging - Track all automation actions\n🚀 Quick Start\nInstallation\n\nFirst, install required dependencies:\n\npip install pyautogui pillow opencv-python pygetwindow\n\nBasic Usage\nfrom skills.desktop_control import DesktopController\n\n# Initialize controller\ndc = DesktopController(failsafe=True)\n\n# Mouse operations\ndc.move_mouse(500, 300)  # Move to coordinates\ndc.click()  # Left click at current position\ndc.click(100, 200, button=\"right\")  # Right click at position\n\n# Keyboard operations\ndc.type_text(\"Hello from OpenClaw!\")\ndc.hotkey(\"ctrl\", \"c\")  # Copy\ndc.press(\"enter\")\n\n# Screen operations\nscreenshot = dc.screenshot()\nposition = dc.get_mouse_position()\n\n📋 Complete API Reference\nMouse Functions\nmove_mouse(x, y, duration=0, smooth=True)\n\nMove mouse to absolute screen coordinates.\n\nParameters:\n\nx (int): X coordinate (pixels from left)\ny (int): Y coordinate (pixels from top)\nduration (float): Movement time in seconds (0 = instant, 0.5 = smooth)\nsmooth (bool): Use bezier curve for natural movement\n\nExample:\n\n# Instant movement\ndc.move_mouse(1000, 500)\n\n# Smooth 1-second movement\ndc.move_mouse(1000, 500, duration=1.0)\n\nmove_relative(x_offset, y_offset, duration=0)\n\nMove mouse relative to current position.\n\nParameters:\n\nx_offset (int): Pixels to move horizontally (positive = right)\ny_offset (int): Pixels to move vertically (positive = down)\nduration (float): Movement time in seconds\n\nExample:\n\n# Move 100px right, 50px down\ndc.move_relative(100, 50, duration=0.3)\n\nclick(x=None, y=None, button='left', clicks=1, interval=0.1)\n\nPerform mouse click.\n\nParameters:\n\nx, y (int, optional): Coordinates to click (None = current position)\nbutton (str): 'left', 'right', 'middle'\nclicks (int): Number of clicks (1 = single, 2 = double)\ninterval (float): Delay between multiple clicks\n\nExample:\n\n# Simple left click\ndc.click()\n\n# Double-click at specific position\ndc.click(500, 300, clicks=2)\n\n# Right-click\ndc.click(button='right')\n\ndrag(start_x, start_y, end_x, end_y, duration=0.5, button='left')\n\nDrag and drop operation.\n\nParameters:\n\nstart_x, start_y (int): Starting coordinates\nend_x, end_y (int): Ending coordinates\nduration (float): Drag duration\nbutton (str): Mouse button to use\n\nExample:\n\n# Drag file from desktop to folder\ndc.drag(100, 100, 500, 500, duration=1.0)\n\nscroll(clicks, direction='vertical', x=None, y=None)\n\nScroll mouse wheel.\n\nParameters:\n\nclicks (int): Scroll amount (positive = up/left, negative = down/right)\ndirection (str): 'vertical' or 'horizontal'\nx, y (int, optional): Position to scroll at\n\nExample:\n\n# Scroll down 5 clicks\ndc.scroll(-5)\n\n# Scroll up 10 clicks\ndc.scroll(10)\n\n# Horizontal scroll\ndc.scroll(5, direction='horizontal')\n\nget_mouse_position()\n\nGet current mouse coordinates.\n\nReturns: (x, y) tuple\n\nExample:\n\nx, y = dc.get_mouse_position()\nprint(f\"Mouse is at: {x}, {y}\")\n\nKeyboard Functions\ntype_text(text, interval=0, wpm=None)\n\nType text with configurable speed.\n\nParameters:\n\ntext (str): Text to type\ninterval (float): Delay between keystrokes (0 = instant)\nwpm (int, optional): Words per minute (overrides interval)\n\nExample:\n\n# Instant typing\ndc.type_text(\"Hello World\")\n\n# Human-like typing at 60 WPM\ndc.type_text(\"Hello World\", wpm=60)\n\n# Slow typing with 0.1s between keys\ndc.type_text(\"Hello World\", interval=0.1)\n\npress(key, presses=1, interval=0.1)\n\nPress and release a key.\n\nParameters:\n\nkey (str): Key name (see Key Names section)\npresses (int): Number of times to press\ninterval (float): Delay between presses\n\nExample:\n\n# Press Enter\ndc.press('enter')\n\n# Press Space 3 times\ndc.press('space', presses=3)\n\n# Press Down arrow\ndc.press('down')\n\nhotkey(*keys, interval=0.05)\n\nExecute keyboard shortcut.\n\nParameters:\n\n*keys (str): Keys to press together\ninterval (float): Delay between key presses\n\nExample:\n\n# Copy (Ctrl+C)\ndc.hotkey('ctrl', 'c')\n\n# Paste (Ctrl+V)\ndc.hotkey('ctrl', 'v')\n\n# Open Run dialog (Win+R)\ndc.hotkey('win', 'r')\n\n# Save (Ctrl+S)\ndc.hotkey('ctrl', 's')\n\n# Select All (Ctrl+A)\ndc.hotkey('ctrl', 'a')\n\nkey_down(key) / key_up(key)\n\nManually control key state.\n\nExample:\n\n# Hold Shift\ndc.key_down('shift')\ndc.type_text(\"hello\")  # Types \"HELLO\"\ndc.key_up('shift')\n\n# Hold Ctrl and click (for multi-select)\ndc.key_down('ctrl')\ndc.click(100, 100)\ndc.click(200, 100)\ndc.key_up('ctrl')\n\nScreen Functions\nscreenshot(region=None, filename=None)\n\nCapture screen or region.\n\nParameters:\n\nregion (tuple, optional): (left, top, width, height) for partial capture\nfilename (str, optional): Path to save image\n\nReturns: PIL Image object\n\nExample:\n\n# Full screen\nimg = dc.screenshot()\n\n# Save to file\ndc.screenshot(filename=\"screenshot.png\")\n\n# Capture specific region\nimg = dc.screenshot(region=(100, 100, 500, 300))\n\nget_pixel_color(x, y)\n\nGet color of pixel at coordinates.\n\nReturns: RGB tuple (r, g, b)\n\nExample:\n\nr, g, b = dc.get_pixel_color(500, 300)\nprint(f\"Color at (500, 300): RGB({r}, {g}, {b})\")\n\nfind_on_screen(image_path, confidence=0.8)\n\nFind image on screen (requires OpenCV).\n\nParameters:\n\nimage_path (str): Path to template image\nconfidence (float): Match threshold (0-1)\n\nReturns: (x, y, width, height) or None\n\nExample:\n\n# Find button on screen\nlocation = dc.find_on_screen(\"button.png\")\nif location:\n    x, y, w, h = location\n    # Click center of found image\n    dc.click(x + w//2, y + h//2)\n\nget_screen_size()\n\nGet screen resolution.\n\nReturns: (width, height) tuple\n\nExample:\n\nwidth, height = dc.get_screen_size()\nprint(f\"Screen: {width}x{height}\")\n\nWindow Functions\nget_all_windows()\n\nList all open windows.\n\nReturns: List of window titles\n\nExample:\n\nwindows = dc.get_all_windows()\nfor title in windows:\n    print(f\"Window: {title}\")\n\nactivate_window(title_substring)\n\nBring window to front by title.\n\nParameters:\n\ntitle_substring (str): Part of window title to match\n\nExample:\n\n# Activate Chrome\ndc.activate_window(\"Chrome\")\n\n# Activate VS Code\ndc.activate_window(\"Visual Studio Code\")\n\nget_active_window()\n\nGet currently focused window.\n\nReturns: Window title (str)\n\nExample:\n\nactive = dc.get_active_window()\nprint(f\"Active window: {active}\")\n\nClipboard Functions\ncopy_to_clipboard(text)\n\nCopy text to clipboard.\n\nExample:\n\ndc.copy_to_clipboard(\"Hello from OpenClaw!\")\n\nget_from_clipboard()\n\nGet text from clipboard.\n\nReturns: str\n\nExample:\n\ntext = dc.get_from_clipboard()\nprint(f\"Clipboard: {text}\")\n\n⌨️ Key Names Reference\nAlphabet Keys\n\n'a' through 'z'\n\nNumber Keys\n\n'0' through '9'\n\nFunction Keys\n\n'f1' through 'f24'\n\nSpecial Keys\n'enter' / 'return'\n'esc' / 'escape'\n'space' / 'spacebar'\n'tab'\n'backspace'\n'delete' / 'del'\n'insert'\n'home'\n'end'\n'pageup' / 'pgup'\n'pagedown' / 'pgdn'\nArrow Keys\n'up' / 'down' / 'left' / 'right'\nModifier Keys\n'ctrl' / 'control'\n'shift'\n'alt'\n'win' / 'winleft' / 'winright'\n'cmd' / 'command' (Mac)\nLock Keys\n'capslock'\n'numlock'\n'scrolllock'\nPunctuation\n'.' / ',' / '?' / '!' / ';' / ':'\n'[' / ']' / '{' / '}'\n'(' / ')'\n'+' / '-' / '*' / '/' / '='\n🛡️ Safety Features\nFailsafe Mode\n\nMove mouse to any corner of the screen to abort all automation.\n\n# Enable failsafe (enabled by default)\ndc = DesktopController(failsafe=True)\n\nPause Control\n# Pause all automation for 2 seconds\ndc.pause(2.0)\n\n# Check if automation is safe to proceed\nif dc.is_safe():\n    dc.click(500, 500)\n\nApproval Mode\n\nRequire user confirmation before actions:\n\ndc = DesktopController(require_approval=True)\n\n# This will ask for confirmation\ndc.click(500, 500)  # Prompt: \"Allow click at (500, 500)? [y/n]\"\n\n🎨 Advanced Examples\nExample 1: Automated Form Filling\ndc = DesktopController()\n\n# Click name field\ndc.click(300, 200)\ndc.type_text(\"John Doe\", wpm=80)\n\n# Tab to next field\ndc.press('tab')\ndc.type_text(\"john@example.com\", wpm=80)\n\n# Tab to password\ndc.press('tab')\ndc.type_text(\"SecurePassword123\", wpm=60)\n\n# Submit form\ndc.press('enter')\n\nExample 2: Screenshot Region and Save\n# Capture specific area\nregion = (100, 100, 800, 600)  # left, top, width, height\nimg = dc.screenshot(region=region)\n\n# Save with timestamp\nimport datetime\ntimestamp = datetime.datetime.now().strftime(\"%Y%m%d_%H%M%S\")\nimg.save(f\"capture_{timestamp}.png\")\n\nExample 3: Multi-File Selection\n# Hold Ctrl and click multiple files\ndc.key_down('ctrl')\ndc.click(100, 200)  # First file\ndc.click(100, 250)  # Second file\ndc.click(100, 300)  # Third file\ndc.key_up('ctrl')\n\n# Copy selected files\ndc.hotkey('ctrl', 'c')\n\nExample 4: Window Automation\n# Activate Calculator\ndc.activate_window(\"Calculator\")\ntime.sleep(0.5)\n\n# Type calculation\ndc.type_text(\"5+3=\", interval=0.2)\ntime.sleep(0.5)\n\n# Take screenshot of result\ndc.screenshot(filename=\"calculation_result.png\")\n\nExample 5: Drag & Drop File\n# Drag file from source to destination\ndc.drag(\n    start_x=200, start_y=300,  # File location\n    end_x=800, end_y=500,       # Folder location\n    duration=1.0                 # Smooth 1-second drag\n)\n\n⚡ Performance Tips\nUse instant movements for speed: duration=0\nBatch operations instead of individual calls\nCache screen positions instead of recalculating\nDisable failsafe for maximum performance (use with caution)\nUse hotkeys instead of menu navigation\n⚠️ Important Notes\nScreen coordinates start at (0, 0) in top-left corner\nMulti-monitor setups may have negative coordinates for secondary displays\nWindows DPI scaling may affect coordinate accuracy\nFailsafe corners are: (0,0), (width-1, 0), (0, height-1), (width-1, height-1)\nSome applications may block simulated input (games, secure apps)\n🔧 Troubleshooting\nMouse not moving to correct position\nCheck DPI scaling settings\nVerify screen resolution matches expectations\nUse get_screen_size() to confirm dimensions\nKeyboard input not working\nEnsure target application has focus\nSome apps require admin privileges\nTry increasing interval for reliability\nFailsafe triggering accidentally\nIncrease screen border tolerance\nMove mouse away from corners during normal use\nDisable if needed: DesktopController(failsafe=False)\nPermission errors\nRun Python with administrator privileges for some operations\nSome secure applications block automation\n📦 Dependencies\nPyAutoGUI - Core automation engine\nPillow - Image processing\nOpenCV (optional) - Image recognition\nPyGetWindow - Window management\n\nInstall all:\n\npip install pyautogui pillow opencv-python pygetwindow\n\n\nBuilt for OpenClaw - The ultimate desktop automation companion 🦞"
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/wpegley/desktop-control-1-0-0",
    "publisherUrl": "https://clawhub.ai/wpegley/desktop-control-1-0-0",
    "owner": "wpegley",
    "version": "1.0.0",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/desktop-control-1-0-0",
    "downloadUrl": "https://openagent3.xyz/downloads/desktop-control-1-0-0",
    "agentUrl": "https://openagent3.xyz/skills/desktop-control-1-0-0/agent",
    "manifestUrl": "https://openagent3.xyz/skills/desktop-control-1-0-0/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/desktop-control-1-0-0/agent.md"
  }
}