GLM-Image
GLM-Image is an open-source image generation model that combines an autoregressive image-token generator with a diffusion decoder to produce high-fidelity results with strong prompt adherence. It is especially strong at accurate text rendering inside images and knowledge-intensive compositions, and it supports image-to-image generation for instruction-driven edits within a single unified model.
API Options
Platform-level options for task execution and delivery.
-
taskType
string required value: imageInference -
Identifier for the type of task being performed
-
taskUUID
string required UUID v4 -
UUID v4 identifier for tracking tasks and matching async responses. Must be unique per task.
-
outputType
string default: URL -
Image output type.
Allowed values 3 values
-
outputFormat
string default: JPG -
Specifies the file format of the generated output. The available values depend on the task type and the specific model's capabilities.
- `JPG`: Best for photorealistic images with smaller file sizes (no transparency).
- `PNG`: Lossless compression, supports high quality and transparency (alpha channel).
- `WEBP`: Modern format providing superior compression and transparency support.
**Transparency**: If you are using features like background removal or LayerDiffuse that require transparency, you must select a format that supports an alpha channel (e.g., `PNG`, `WEBP`, `TIFF`). `JPG` does not support transparency.Allowed values 3 values
-
outputQuality
integer min: 20 max: 99 default: 95 -
Compression quality of the output. Higher values preserve quality but increase file size.
-
webhookURL
string URI -
Specifies a webhook URL where JSON responses will be sent via HTTP POST when generation tasks complete. For batch requests with multiple results, each completed item triggers a separate webhook call as it becomes available.
Learn more 1 resource
- Webhooks PLATFORM
- Webhooks
-
deliveryMethod
string default: sync -
Determines how the API delivers task results.
Allowed values 2 values
- Returns complete results directly in the API response.
- Returns an immediate acknowledgment with the task UUID. Poll for results using getResponse.
Learn more 1 resource
- Task Polling PLATFORM
-
uploadEndpoint
string URI -
Specifies a URL where the generated content will be automatically uploaded using the HTTP PUT method. The raw binary data of the media file is sent directly as the request body. For secure uploads to cloud storage, use presigned URLs that include temporary authentication credentials.
Common use cases:
- Cloud storage: Upload directly to S3 buckets, Google Cloud Storage, or Azure Blob Storage using presigned URLs.
- CDN integration: Upload to content delivery networks for immediate distribution.
// S3 presigned URL for secure upload https://your-bucket.s3.amazonaws.com/generated/content.mp4?X-Amz-Signature=abc123&X-Amz-Expires=3600 // Google Cloud Storage presigned URL https://storage.googleapis.com/your-bucket/content.jpg?X-Goog-Signature=xyz789 // Custom storage endpoint https://storage.example.com/uploads/generated-image.jpgThe content data will be sent as the request body to the specified URL when generation is complete.
-
safety
object -
Content safety checking configuration for image generation.
Properties 2 properties
-
safety»checkContentcheckContent
boolean default: false -
Enable or disable content safety checking. When enabled, defaults to
fastmode.
-
safety»modemode
string default: none -
Safety checking mode for image generation.
Allowed values 2 values
- Disables checking.
- Performs a single check.
-
-
ttl
integer min: 60 -
Time-to-live (TTL) in seconds for generated content. Only applies when
outputTypeisURL.
-
includeCost
boolean default: false -
Include task cost in the response.
-
numberResults
integer min: 1 max: 20 default: 1 -
Number of results to generate. Each result uses a different seed, producing variations of the same parameters.
Inputs
Input resources for the task (images, audio, etc). These must be nested inside the inputs object.
inputs object.-
inputs»referenceImagesreferenceImages
array of strings items: 1 -
List of reference images (UUID, URL, Data URI, or Base64).
Generation Parameters
Core parameters for controlling the generated content.
-
model
string required value: runware:glm-image@0 -
Identifier of the model to use for generation.
Learn more 3 resources
-
positivePrompt
string required min: 2 max: 3000 -
Text prompt describing elements to include in the generated output.
Learn more 2 resources
-
width
integer required min: 128 max: 2048 default: 1024 -
Width of the generated media in pixels.
Learn more 2 resources
-
height
integer required min: 128 max: 2048 default: 1024 -
Height of the generated media in pixels.
Learn more 2 resources
-
seed
integer min: 0 max: 9223372036854776000 -
Random seed for reproducible generation. When not provided, a random seed is generated in the unsigned 32-bit range.
Learn more 1 resource
-
steps
integer min: 1 max: 999 default: 100 -
Total number of denoising steps. Higher values generally produce more detailed results but take longer.
Learn more 1 resource
-
CFGScale
float min: 1 max: 30 step: 0.01 default: 10 -
Guidance scale representing how closely the output will resemble the prompt. Higher values produce results more aligned with the prompt.
Learn more 1 resource
Handwritten Atlas Reading Room
{
"taskType": "imageInference",
"taskUUID": "03ada9c5-16e0-409a-b2b7-9c77d7b51757",
"model": "runware:glm-image@0",
"positivePrompt": "A grand reading room inside a 19th-century geographical society, towering walnut shelves filled with atlases, suspended brass globe lamps, rolled charts, measuring tools, and a massive painted world map on the far wall. At the center, a long oak table displays open map folios, compasses, magnifiers, and labeled specimen boxes. A librarian in a deep green coat arranges documents while two travelers study routes marked in red ink. Warm amber daylight pours through tall arched windows, carrying floating dust motes and creating soft directional shadows. Include several pieces of clearly legible handwritten and engraved text in the scene: a hanging sign that reads \"Cartography Hall\", a book spine labeled \"Polar Routes 1874\", a crate tag reading \"River Survey\", and a map title saying \"Atlas of Winds\". Highly detailed, realistic textures, cinematic composition, elegant historical atmosphere, natural color palette, precise architecture, crisp focus.",
"width": 1024,
"height": 768,
"seed": 45732,
"steps": 40,
"CFGScale": 7.5
}{
"taskType": "imageInference",
"taskUUID": "03ada9c5-16e0-409a-b2b7-9c77d7b51757",
"imageUUID": "bb7d4356-03ae-481b-b687-68f3c4f7a00f",
"imageURL": "https://im.runware.ai/image/os/a13d12/ws/2/ii/bb7d4356-03ae-481b-b687-68f3c4f7a00f.jpg",
"seed": 45732,
"cost": 0.0141
}Floating Archive Atrium Diorama
{
"taskType": "imageInference",
"taskUUID": "cfa556ea-2c34-45d9-8800-487dcf83082c",
"model": "runware:glm-image@0",
"positivePrompt": "A richly detailed cutaway diorama of a floating public archive drifting above a patchwork floodplain at sunrise, built from weathered cedar, brass braces, glass walkways, hanging rope bridges, and suspended reading pods. Inside the multi-level atrium: librarians, cartographers, and schoolchildren studying oversized maps, seed catalogs, river specimens, and hand-labeled drawers. Accurate readable signage integrated into the scene: a carved wooden entry sign that says \"SKY TIDE ARCHIVE\", a wayfinding board with arrows labeled \"MAP ROOM\", \"SEED VAULT\", and \"UPPER STACKS\", and a small stamp on a crate reading \"DELIVER TO DELTA SCHOOL\". Outside the windows: flocks of white ibises, terraced wetlands, tiny ferries below, and distant wind pumps. Style: highly imaginative cinematic illustration with crisp focus, tactile materials, atmospheric depth, warm amber and pale turquoise palette, elegant composition, abundant micro-details, believable scale, soft sunbeams, uplifting and curious mood.",
"width": 1024,
"height": 768,
"seed": 25044,
"steps": 40,
"CFGScale": 7.5
}{
"taskType": "imageInference",
"taskUUID": "cfa556ea-2c34-45d9-8800-487dcf83082c",
"imageUUID": "6682a474-f4a1-4ebf-8ce3-30066c62cb14",
"imageURL": "https://im.runware.ai/image/os/a17d13/ws/2/ii/6682a474-f4a1-4ebf-8ce3-30066c62cb14.jpg",
"seed": 25044,
"cost": 0.0147
}Riverside Herbarium Signboard Tableau
{
"taskType": "imageInference",
"taskUUID": "2ac419c1-a561-4f61-9bb8-4c44f797ad37",
"model": "runware:glm-image@0",
"positivePrompt": "Transform the reference image into a highly detailed riverside herbarium display beneath a striped canvas awning on a breezy spring afternoon. Keep the tabletop arrangement recognizable, but expand it into a story-rich scene with labeled glass jars, pressed plant specimens, seed packets, handwritten botanical cards, bundles of sage and lavender, copper clips, a folded field journal, and a painted wooden sign that clearly reads 'RIVERBANK HERBARIUM'. Add a second smaller label card that clearly reads 'Specimens & Seeds'. In the background, include a calm canal, moored rowboats, willow branches, and weathered stone steps. Natural color palette, crisp textures, realistic lighting, documentary-style composition, high fidelity, precise text rendering, subtle human presence implied by recently used tools but no visible person.",
"width": 1024,
"height": 768,
"seed": 16029,
"steps": 40,
"CFGScale": 7.5,
"inputs": {
"referenceImages": [
"https://assets.runware.ai/assets/inputs/298877df-be25-4bd9-8813-1990e7d9e8f4.jpg"
]
}
}{
"taskType": "imageInference",
"taskUUID": "2ac419c1-a561-4f61-9bb8-4c44f797ad37",
"imageUUID": "ec273ad7-92c9-4e5f-9cb7-85c4be50fd6b",
"imageURL": "https://im.runware.ai/image/os/a25d05/ws/2/ii/ec273ad7-92c9-4e5f-9cb7-85c4be50fd6b.jpg",
"seed": 16029,
"cost": 0.0397
}Wayfinding Mural Transit Hall
{
"taskType": "imageInference",
"taskUUID": "939d44af-db29-4f24-a066-183d5f52b88c",
"model": "runware:glm-image@0",
"positivePrompt": "Transform the reference image into a grand contemporary transit hall centered around a massive hand-painted wayfinding mural and integrated signage system. Preserve the overall architecture and camera perspective from the source image, but enrich the walls, floor accents, and overhead panels with a cohesive visual identity inspired by geology, rivers, and regional history. Include highly legible text rendered directly inside the scene: a central wall title reading \"RIVERGATE CENTRAL\", directional signs reading \"PLATFORM A\", \"PLATFORM B\", \"TICKETS\", \"EXIT\", and \"CITY TRAMS\", plus a large infographic map labeled \"REGIONAL LINES\" with small route names and icons. Add suspended colored markers, tactile floor strips, benches, subtle traveler silhouettes, and polished stone surfaces. Clean natural daylight, precise typography, balanced composition, realistic materials, sharp details, documentary architectural photography feel.",
"width": 1024,
"height": 768,
"seed": 28031,
"steps": 40,
"CFGScale": 7.5,
"inputs": {
"referenceImages": [
"https://assets.runware.ai/assets/inputs/a4b32105-2b05-4d19-a825-de1f9a816066.jpg"
]
}
}{
"taskType": "imageInference",
"taskUUID": "939d44af-db29-4f24-a066-183d5f52b88c",
"imageUUID": "8d4589d0-382f-4cac-bce2-2044dfaa799c",
"imageURL": "https://im.runware.ai/image/os/a08d21/ws/2/ii/8d4589d0-382f-4cac-bce2-2044dfaa799c.jpg",
"seed": 28031,
"cost": 0.0378
}