Image Generator Block
Generate images
The Image Generator block creates high-quality images using OpenAI's image generation models. Reach for it whenever a workflow needs to turn a text prompt into an image, with control over resolution, quality, style, and background.
Overview
| Property | Value |
|---|---|
| Type | image_generator |
| Category | tools |
| Color | #C2410C |
When to Use
- Generate marketing or social media visuals from a text description
- Produce illustrations or concept art on demand inside a workflow
- Create product mockups or hero images for landing pages
- Generate transparent-background assets (with GPT Image) for compositing
- Turn upstream AI-generated prompts into finished images automatically
- Chain the output image into a downstream vision block for further processing
Configuration
Model
Dropdown to choose the generation model. Defaults to dall-e-3. The selected model controls which Size, Quality, Style, and Background sub-blocks appear.
| Label | Id |
|---|---|
| DALL-E 3 | dall-e-3 |
| GPT Image | gpt-image-1 |
Prompt
Required long-input field. Describe the image you want to generate. Supports {{blockName.field}} references to inject dynamic content from upstream blocks.
Size (DALL-E 3)
Shown when Model is dall-e-3. Defaults to 1024x1024.
| Label | Id |
|---|---|
| 1024x1024 | 1024x1024 |
| 1024x1792 | 1024x1792 |
| 1792x1024 | 1792x1024 |
Size (GPT Image)
Shown when Model is gpt-image-1. Defaults to auto.
| Label | Id |
|---|---|
| Auto | auto |
| 1024x1024 | 1024x1024 |
| 1536x1024 | 1536x1024 |
| 1024x1536 | 1024x1536 |
Quality
Shown when Model is dall-e-3. Defaults to standard.
| Label | Id |
|---|---|
| Standard | standard |
| HD | hd |
Style
Shown when Model is dall-e-3. Defaults to vivid.
| Label | Id |
|---|---|
| Vivid | vivid |
| Natural | natural |
Background
Shown when Model is gpt-image-1. Defaults to auto.
| Label | Id |
|---|---|
| Auto | auto |
| Transparent | transparent |
| Opaque | opaque |
API Key
Required. Your OpenAI API key used to authorize the generation request. Marked as a password field; use {{OPENAI_API_KEY}} to pull the value from an environment secret.
Inputs & Outputs
-
Inputs:
prompt(string) — Image description promptmodel(string) — Image generation model (dall-e-3orgpt-image-1)size(string) — Image dimensionsquality(string) — Image quality level (DALL-E 3 only:standardorhd)style(string) — Image style (DALL-E 3 only:vividornatural)background(string) — Background type (GPT Image only:auto,transparent, oropaque)apiKey(string) — OpenAI API key
-
Outputs:
content(string) — Generation response: the image URL returned by OpenAI (DALL-E 3) or the stringdirect-imagewhen base64 data is returned directly (GPT Image)image(string) — Base64-encoded image data (PNG); always populated after the proxy fetchmetadata(json) — Generation metadata, including themodelname used
Tools
Image Generator (openai_image) — Calls POST https://api.openai.com/v1/images/generations with the configured model, prompt, size, and model-specific options. For DALL-E 3 responses, the tool fetches the time-limited CDN URL via a server-side proxy and converts the image to a base64 string. For GPT Image, base64 is returned directly by the API. The tool exposes content (URL or identifier), image (base64 data), and metadata (model name) on success.
YAML Example
image_generator_1:
type: image_generator
name: "Image Generator"
inputs:
model: "dall-e-3"
prompt: "{{start.input}}"
size: "1024x1024"
quality: "standard"
style: "vivid"
apiKey: "{{OPENAI_API_KEY}}"
connections:
outgoing:
- target: next-block-id