Upload images to ImageKit from file paths or clipboard, returning the CDN URL for easy sharing and embedding
A generic agent skill for uploading images to ImageKit CDN from file paths or clipboard.
cd ~/.claude/skills/imagekit-upload/scripts
Install required packages:
npm install
This installs:
imagekit - ImageKit SDKdotenv - Environment variable managementclipboardy - Clipboard support for macOSCreate a .env file from the example:
cp .env.example .env
Edit the .env file and add your ImageKit credentials:
IMAGEKIT_PUBLIC_KEY=your_public_key_here
IMAGEKIT_PRIVATE_KEY=your_private_key_here
IMAGEKIT_URL_ENDPOINT=https://ik.imagekit.io/your_id
You can find these credentials in your ImageKit dashboard under Developer Options → API Keys.
Try uploading a test image:
node ~/.claude/skills/imagekit-upload/scripts/upload.js --file "/path/to/test-image.jpg"
# Basic upload
node scripts/upload.js --file "/path/to/image.jpg"
# Upload with custom name
node scripts/upload.js --file "/path/to/image.jpg" --name "my-custom-name"
# Upload to specific folder
node scripts/upload.js --file "/path/to/image.jpg" --folder "/brand/logos"
# Upload with tags
node scripts/upload.js --file "/path/to/image.jpg" --tags "logo,brand,2024"
# Combine options
node scripts/upload.js --file "/path/to/image.jpg" --name "company-logo" --folder "/brand" --tags "logo,primary"
# Upload image from clipboard
node scripts/upload.js --clipboard
# Upload from clipboard with custom name
node scripts/upload.js --clipboard --name "screenshot-$(date +%Y%m%d)"
Once set up, you can use this skill by invoking it in your agent environment:
User: Upload this screenshot to ImageKit: /tmp/screenshot.png
Agent: [Invokes skill and uploads the image]
User: I just copied an image, upload it to ImageKit
Agent: [Uses --clipboard flag to upload from clipboard]
Make sure you've created the .env file in the scripts directory with all three required variables.
Run npm install in the scripts directory.
Verify the file path is correct and the file exists.
This feature currently only works on macOS. Make sure you've copied an image to your clipboard before running the command.
The script returns a JSON object with:
{
"success": true,
"url": "https://ik.imagekit.io/your_id/image.jpg",
"fileId": "abc123...",
"name": "image.jpg",
"size": 123456,
"filePath": "/image.jpg",
"thumbnailUrl": "https://ik.imagekit.io/your_id/tr:n-media_library_thumbnail/image.jpg"
}
The url field contains the CDN URL you can use to access your image.
Search for places (restaurants, cafes, etc.) via Google Places API proxy on localhost.
Interact with GitHub using the `gh` CLI. Use `gh issue`, `gh pr`, `gh run`, and `gh api` for issues, PRs, CI runs, and advanced queries.
Create or update AgentSkills. Use when designing, structuring, or packaging skills with scripts, references, and assets.
Start voice calls via the OpenClaw voice-call plugin.
Notion API for creating and managing pages, databases, and blocks.
Gemini CLI for one-shot Q&A, summaries, and generation.
Category:developer