Clipboard history

From taracodlabs/aiden · View interactive version

Clipboard history is an AI agent skill from the GitHub repository taracodlabs/aiden. Read/write Windows clipboard text, HTML, images, history (PowerShell)

How to use this skill

Skill file

Clipboard History

Read and write Windows clipboard content, access clipboard history (Win+V), and manipulate clipboard data — text, HTML, and file lists — via PowerShell.

When to Use

How to Use

Read current clipboard text

Get-Clipboard

Write text to clipboard

Set-Clipboard -Value "Hello from Aiden!"

Pipe command output to clipboard

Get-Process | Out-String | Set-Clipboard

Copy a file path to clipboard

Set-Clipboard -Value "C:\Users\<you>\Documents\report.pdf"

Clear the clipboard

Set-Clipboard -Value $null

Read clipboard as HTML (if HTML is on clipboard)

Add-Type -AssemblyName System.Windows.Forms
[System.Windows.Forms.Clipboard]::GetText([System.Windows.Forms.TextDataFormat]::Html)

Check if clipboard contains an image

Add-Type -AssemblyName System.Windows.Forms
[System.Windows.Forms.Clipboard]::ContainsImage()

Save clipboard image to file

Add-Type -AssemblyName System.Windows.Forms
$img = [System.Windows.Forms.Clipboard]::GetImage()
if ($img) {
  $img.Save("$env:USERPROFILE\Desktop\clipboard-image.png")
  Write-Host "Saved to Desktop"
} else {
  Write-Host "No image on clipboard"
}

Access clipboard history entries (Win+V API)

# Clipboard history requires Windows 10 1809+ and history enabled in Settings
# Use the ContentDeliveryManager workaround or UWP API via PowerShell
Add-Type -AssemblyName Windows.ApplicationModel
$history = [Windows.ApplicationModel.DataTransfer.Clipboard,Windows.ApplicationModel,ContentType=WindowsRuntime]
# Note: full UWP clipboard history requires a packaged app context
# For CLI use, pipe history via the built-in Win+V UI or a third-party tool
Write-Host "Open Win+V to view clipboard history interactively"

Examples

"Copy the output of dir to clipboard"

→ Get-ChildItem | Out-String | Set-Clipboard

"Put my public IP address on the clipboard"

→ (Invoke-RestMethod -Uri 'https://api.ipify.org').Trim() | Set-Clipboard

"Clear whatever is on the clipboard"

→ Set-Clipboard -Value $null

Cautions

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.