Unified API access to multiple AI models via kie.ai - image generation (Nano Banana Pro, Flux), video (Veo), music (Suno). 30-80% cheaper than official APIs.
概览
Unified access to multiple AI models through kie.ai's API. Generate images, videos, and music at 30-80% lower cost than official APIs. - 🎨 : Nano Banana Pro (Gemini 3 Pro), Flux, 4o-image - 📤 : Optional automatic upload to Drive folder - 📊 : Local task history and cost estimation - 💾 : All files saved to images/ before optional upload - 🎬 (coming soon): Veo 3.1, Runway Gen-4 Aleph - 🎵 (coming soon): Suno V4/V4.5 1. (usually pre-installed on macOS/Linux) 2. : - Sign up at https://kie.ai - Get API key from dashboard 1. Add API key to ~/.openclaw/openclaw.json: Shows: - Local task history - Estimated credit consumption - USD equivalent - Links to web UI for actual balance 1. Sign up at https://maton.ai (OAuth gateway) 2. Add MATON_API_KEY to environment 3. Create Google Drive connection at https://ctrl.maton.ai 4. Get folder ID from Drive URL Approximate costs (kie.ai vs official APIs): - nano-banana-pro - Gemini 3 Pro Image (1K/2K/4K) - google/nano-banana - Gemini 2.
README
以下为原文 README 节选,完整内容请查看原文。
kie.ai API Wrapper for OpenClaw
Unified access to multiple AI models through kie.ai’s API. Generate images, videos, and music at 30-80% lower cost than official APIs.
Features
- 🎨 Image Generation: Nano Banana Pro (Gemini 3 Pro), Flux, 4o-image
- 📤 Google Drive Upload: Optional automatic upload to Drive folder
- 📊 Usage Tracking: Local task history and cost estimation
- 💾 Local Storage: All files saved to
images/before optional upload - 🎬 Video Generation (coming soon): Veo 3.1, Runway Gen-4 Aleph
- 🎵 Music Generation (coming soon): Suno V4/V4.5
Quick Start
# Generate an image
./kie-ai.sh generate-image "A serene Japanese garden at sunset"
# With custom options
./kie-ai.sh generate-image "Cyberpunk city" --resolution 2K --aspect 16:9
# Upload to Google Drive
./kie-ai.sh generate-image "Space nebula" --upload-drive
# Check usage
./kie-ai.sh balance
Installation
Prerequisites
- Python 3.6+ (usually pre-installed on macOS/Linux)
- kie.ai API Key:
- Sign up at https://kie.ai
- Get API key from dashboard
Setup
# Clone the repo
cd ~/src
git clone https://github.com/jon-xo/kie-ai-skill.git
cd kie-ai-skill
# Make executable
chmod +x kie-ai.sh lib/*.py
# Set your API key
export KIE_API_KEY="your-key-here"
# Test it
./kie-ai.sh generate-image "test image"
OpenClaw Integration
If using with OpenClaw:
-
Add API key to
~/.openclaw/openclaw.json:"env": { "vars": { "KIE_API_KEY": "your-key-here" } } -
Create symlink:
ln -s ~/src/kie-ai-skill ~/.openclaw/workspace/skills/kie-ai-skill
Usage
Image Generation
./kie-ai.sh generate-image [options]
Options:
--model Model (default: nano-banana-pro)
--resolution 1K, 2K, 4K (default: 1K)
--aspect 1:1, 16:9, 9:16, etc. (default: 1:1)
--upload-drive Upload to Google Drive after generation
Examples:
# Basic
./kie-ai.sh generate-image "A red apple on a wooden table"
# High resolution widescreen
./kie-ai.sh generate-image "Mountain landscape" --resolution 4K --aspect 16:9
# 16-bit pixel art style
./kie-ai.sh generate-image "Cyberpunk lobster, 16-bit pixel art, no text"
# Generate and upload to Drive
./kie-ai.sh generate-image "Abstract art" --upload-drive
Check Balance
./kie-ai.sh balance
Shows:
- Local task history
- Estimated credit consumption
- USD equivalent
- Links to web UI for actual balance
List Models
./kie-ai.sh models
Configure Google Drive (Optional)
# View config help
./kie-ai.sh config
# Edit config.json
nano config.json
# Set:
# - enabled: true
# - folder_id: "YOUR_GOOGLE_DRIVE_FOLDER_ID"
Google Drive Setup:
推荐工具
换一个关键词,或者移除筛选条件。
安装
npx skillfish add newtosh/kie-ai-skill