Skip to content

EvoLinkAI/gpt-image-2-gen-skill

Repository files navigation

GPT Image 2 Gen Skill

AI image generation with GPT Image 2, built for OpenClaw, Claude Code, OpenCode, and AI agents that need fast OpenAI-compatible image generation workflows.

GPT-Image-2-AI-Image-Generation-Skill-for-Claude-Code-OpenClaw-and-AI-Agents-by-EvoLinkAI

NPM version MIT License GitHub stars Last commit

MenuInstallShowcaseGPT Image 2API KeyEvoLink

English Español Português 日本語 한국어 Deutsch Français Türkçe 繁體中文 简体中文 Русский


AI Agent? Skip the README, go straight to llms-install.md for step-by-step installation instructions designed for you.


📑 Menu


What is This?

GPT Image 2 Gen Skill is an AI agent image generation skill for OpenClaw, Claude Code, and OpenCode, powered by EvoLink. It gives your agent a fast OpenAI-compatible API integration for GPT Image 2, including text-to-image, image editing, batch generation, and multi-size output workflows.

Skill Description Model
GPT Image 2 Gen Text-to-image, image editing, batch generation GPT Image 2 (OpenAI)

Installation

Quick Install (OpenClaw)

openclaw skills add https://github.com/EvoLinkAI/gpt-image-2-gen-skill

Install via npm (Recommended)

npx evolink-gpt-image

Or non-interactive (for AI agents / CI):

npx evolink-gpt-image -y

Install to a specific directory:

npx evolink-gpt-image -y --path ~/.claude/skills

Manual Install

git clone https://github.com/EvoLinkAI/gpt-image-2-gen-skill.git
cd gpt-image-2-gen-skill
openclaw skills add .

Agent Auto-Install (Copy & Paste to Your Agent)

Tell your AI agent the following prompt, and it will install the skill automatically:

Claude Code

Install the GPT Image 2 generation skill by running:

npx evolink-gpt-image@latest -y --path ~/.claude/skills

After installation, set the API key:

export EVOLINK_API_KEY=your_key_here

Then read the skill file at ~/.claude/skills/gpt-image-2-gen/SKILL.md to learn how to use it.

OpenCode

Install the GPT Image 2 generation skill by running:

npx evolink-gpt-image@latest -y --path ~/.opencode/skills

After installation, set the API key:

export EVOLINK_API_KEY=your_key_here

Then read the skill file at ~/.opencode/skills/gpt-image-2-gen/SKILL.md to learn how to use it.

OpenClaw

Install the GPT Image 2 generation skill by running:

npx evolink-gpt-image@latest -y

The installer will auto-detect your OpenClaw skills directory. After installation, set the API key:

export EVOLINK_API_KEY=your_key_here

One-Liner (Any Agent)

For agents that support shell commands, this single command installs and verifies in one step:

EVOLINK_API_KEY=your_key_here npx evolink-gpt-image@latest -y --path ~/.claude/skills

Replace ~/.claude/skills with ~/.opencode/skills or your agent's skill directory.


Getting an API Key

  1. Sign up at evolink.ai
  2. Go to Dashboard -> API Keys
  3. Create a new key
  4. Set it in your environment:
export EVOLINK_API_KEY=your_key_here

Or tell your AI agent: "Set my EvoLink API key to ..." — it will handle the rest.


🖼️ Showcase

Portrait Styling Product Marketing Character Design
Portrait styling image generated with GPT Image 2 Product marketing visual generated with GPT Image 2 Character design concept generated with GPT Image 2

These examples were selected from the awesome-gpt-image-2-prompts repository. Install the skill, connect your EvoLink API key, and use the GPT Image 2 image generation docs to create similar outputs.


GPT Image 2 Generation

Generate and edit AI images through natural conversation with your AI agent.

What It Can Do

  • Text-to-image — Describe what you want, get an image
  • Image editing — Provide reference images (1-16) and describe edits
  • Batch generation — Generate up to 10 images per request
  • Multiple sizes — 15 ratio presets + custom pixel dimensions
  • Resolution tiers — 1K (~1MP), 2K (~4MP), 4K (~8.3MP)
  • Quality levels — Low (fast), Medium (balanced), High (best)
  • Prompt power — Up to 32,000 characters per prompt

Usage Examples

Just talk to your agent:

"Generate an image of a sunset over the ocean"

"Create a minimalist logo, 1024x1024, high quality"

"Edit this image — add a cat next to the person"

"Generate 4 variations of a pixel art robot in 4K"

The agent will guide you through any missing details and handle the generation.

Requirements

  • curl and jq installed on your system
  • EVOLINK_API_KEY environment variable set

Script Reference

The skill includes scripts/gpt-image-gen.sh for direct command-line use:

# Text-to-image (basic)
./scripts/gpt-image-gen.sh "A beautiful sunset over the ocean"

# High quality 4K widescreen
./scripts/gpt-image-gen.sh "Cinematic cityscape at dusk" --size 16:9 --resolution 4K --quality high

# Custom pixel dimensions
./scripts/gpt-image-gen.sh "Minimalist logo" --size 1024x1024

# Image editing
./scripts/gpt-image-gen.sh "Add a cat next to her" --image "https://example.com/photo.png"

# Batch generation
./scripts/gpt-image-gen.sh "Pixel art robot" --count 4 --quality high

# Dry run (preview payload)
./scripts/gpt-image-gen.sh "Test prompt" --dry-run

API Parameters

See references/api-params.md for complete API documentation.


File Structure

.
├── README.md                    # This file
├── SKILL.md                     # Skill definition (for AI agents)
├── _meta.json                   # Skill metadata
├── bin/
│   └── cli.js                   # npm installer CLI
├── references/
│   └── api-params.md            # Complete API parameter reference
└── scripts/
    └── gpt-image-gen.sh         # Image generation script

Troubleshooting

Issue Solution
jq: command not found Install jq: apt install jq / brew install jq
401 Unauthorized Check your EVOLINK_API_KEY at evolink.ai/dashboard
402 Payment Required Add credits at evolink.ai/dashboard
Content blocked Prompt flagged by moderation — modify your description
Image too large Reference images must be <=50MB each
Generation timeout Images can take 5-90s. Try lower quality/resolution first.

Compatibility

Agent Install Method
OpenClaw openclaw skills add <repo> or npx evolink-gpt-image
Claude Code npx evolink-gpt-image -y --path ~/.claude/skills
OpenCode npx evolink-gpt-image -y --path ~/.opencode/skills
Cursor npx evolink-gpt-image -y --path <your-skills-dir>

License

MIT


Community

Star History

Star History Chart


Powered by EvoLink , Unified AI API Gateway