Skip to content

Feature Image Generation

github-actions[bot] edited this page Apr 26, 2026 · 2 revisions

Feature: Image Generation

ɳClaw supports multi-provider image generation. You can generate images from text prompts through the chat interface or the API, and browse results in the image gallery.

Route: /gallery in claw-web API: POST /claw/image/generate


Supported Providers

Provider Env Var Notes
DALL-E (default) OPENAI_API_KEY OpenAI's image model
Stable Diffusion SD_API_URL Self-hosted or API
Midjourney MJ_API_KEY Via proxy API

Set CLAW_IMAGE_PROVIDER in your .env to choose the default provider. Users can override per-request.

How It Works

  1. Send a prompt via chat or POST /claw/image/generate
  2. The request enters the job queue (np_claw.image_jobs table)
  3. The selected provider processes the request
  4. Results appear in the gallery and in the chat thread

API

Generate Image

POST /claw/image/generate
Content-Type: application/json
Authorization: Bearer {token}

{
  "prompt": "A sunset over mountains in watercolor style",
  "provider": "dall-e",
  "size": "1024x1024"
}

List Jobs

GET /claw/image/jobs

Returns all generation jobs with status (queued, processing, complete, failed).

Get Job

GET /claw/image/jobs/{id}

Returns job details including the generated image URL when complete.

Gallery

The /gallery route in claw-web shows all generated images as cards. Each card displays the prompt, provider, timestamp, and a zoomable preview.

Configuration

Env Var Default Description
CLAW_IMAGE_PROVIDER dall-e Default provider
OPENAI_API_KEY -- Required for DALL-E
SD_API_URL -- Stable Diffusion endpoint
MJ_API_KEY -- Midjourney proxy key

Related

Home


Getting Started


Commands


Features


Configuration


Plugins (87 + 10 monitoring)

Free (25)
Pro (62)
Planned (26)
  • plugin-audit
  • plugin-blog
  • plugin-checkout
  • plugin-commerce
  • plugin-drm
  • plugin-export
  • plugin-flow
  • plugin-import
  • plugin-ldap
  • plugin-mailgun
  • plugin-media
  • plugin-oauth-providers
  • plugin-pages
  • plugin-postmark
  • plugin-rate-limit
  • plugin-reports
  • plugin-saml
  • plugin-scheduler
  • plugin-sendgrid
  • plugin-sso
  • plugin-subscription
  • plugin-thumb
  • plugin-transcoder
  • plugin-twilio
  • plugin-waf
  • plugin-watermark

Guides


Architecture


Reference


Licensing


Security


Brand


Operations


Contributing


Admin


Changelog

Clone this wiki locally