An AI-powered image generation and editing skill running on Node.js and Python, driven by the official SudoCode GPT Image 2 model for high-fidelity 4K visual assets.
The fastest way to install a skill directly from the registry.
npx clawhub@latest install sudocode-gpt-image-2-gen
Copy the skill folder to one of these locations
~/.openclaw/skills/ <project>/skills/ Priority: Workspace > Local > Bundled
Copy this prompt to OpenClaw to install it automatically.
Help me install sudocode-gpt-image-2-gen using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).
Get the raw skill files in a ZIP archive.
The SudoCode GPT Image 2 Generator is a robust and flexible visual asset creation tool designed to integrate seamlessly into developer and AI agent workflows. Operating through the official SudoCode platform, this skill leverages the state-of-the-art gpt-image-2 model to produce highly accurate images, visual infographics, and complex modifications of existing images using natural language instructions. By selecting this skill from the Openclaw Skills directory, developers can leverage programmatic control over pixel dimensions, file formats, compression ratios, and rendering quality.
Unlike traditional wrapper solutions, this skill accesses the official SudoCode endpoints directly, offering a token-based billing structure and full programmatic consistency. It features zero-dependency execution for Node.js environments and a robust fall-back execution model for Python-based environments, making it exceptionally reliable across diverse staging and production systems.
SUDOCODE_API_KEY environment variable or command-line overrides./v1/images/generations (JSON) or /v1/images/edits (multipart/form-data for reference images) endpoint.b64_json) is returned, the engine strips headers, decodes the raw base64 data, and safely saves the resulting file (PNG, JPEG, or WebP) to the designated output folder.Visit SudoCode, sign up or log in, and generate your API Key from the developer console.
Set your API key using your platform's environment variables to authenticate with Openclaw Skills automatically:
# Linux or macOS
export SUDOCODE_API_KEY="your_actual_api_key_here"
# Windows CMD
set SUDOCODE_API_KEY="your_actual_api_key_here"
# Windows PowerShell
$env:SUDOCODE_API_KEY="your_actual_api_key_here"
This skill supports zero-dependency Node.js execution (recommended) and Python scripts. Openclaw Skills will choose the best runtime dynamically:
# Using Node.js (Recommended/Default)
node scripts/generate_image.js -p "A cute orange tabby cat playing on green grass" -f "cat.png"
# Using Python
python scripts/generate_image.py -p "A cute orange tabby cat playing on green grass" -f "cat.png"
The skill processes structured parameters and writes outputs directly to disk. The base64 output (b64_json) returned from the SudoCode API contains no prefix (i.e., pure base64 data), which is handled automatically by the scripts.
| CLI Flag | Short/Long Name | Required | Description | Default / Values |
|---|---|---|---|---|
-p |
--prompt |
Yes | Natural language prompt or editing instruction | User raw input |
-f |
--filename |
No | Target output file name (saves automatically with timestamp if omitted) | Auto-generated |
-s |
--size |
No | Image resolution. Presets include: 1024x1024, 1536x1024, 1024x1536, 2048x2048, 2048x1152, 3840x2160, 2160x3840 | auto (Custom values allowed under 3840 max edge, divisible by 16, ratio <= 3:1) |
-q |
--quality |
No | Render quality profiles | auto, low, medium, high |
-o |
--output-format |
No | Target extension | png, jpeg, webp |
-c |
--output-compression |
No | Compression factor (0-100) for JPEG and WebP | 100 |
-i |
--input-image |
No | Paths to input reference images (up to 5) for image-to-image mode | None |
| Preset Dimensions | Aspect Ratio | Primary Use Case |
|---|---|---|
1024x1024 |
1:1 | Avatars, social icons, Instagram posts |
1536x1024 |
3:2 | Landscape photography, default landscape |
1024x1536 |
2:3 | Standard portrait photography |
2048x2048 |
1:1 | High-definition square illustrations |
2048x1152 |
16:9 | HD video covers, widescreen presentations, desktop wallpapers |
3840x2160 |
16:9 | 4K Ultra HD landscape wallpapers |
2160x3840 |
9:16 | 4K Mobile portrait wallpapers |
Loading
An automated command-line toolkit for batch processing RAW, HEIC, and JPEG images, generating thumbnails, finding photos by date, and creating grid previews.

An advanced Openclaw Skills extension that automates professional-grade RAW, JPG, and HEIC photo color grading using RawTherapee CLI and LLM-generated Lightroom parameters.

An automated AI agent skill that monitors competitors' pricing, social channels, and product changes, compiling actionable intelligence into weekly reports.

An AI-powered skill for orchestrating codebase migrations, library upgrades, AST-first code refactoring, and custom codemod authoring using the Codemod CLI.

A structured AI agent skill designed to help developers create comprehensive, safe, and template-driven README files with ease.

An automated workflow that parses complex articles, scientific papers, or reports and converts them into production-ready science video scripts, shot lists, and visual prompts.








































