HERMES + Z IMAGE

Use Z Image in Hermes Agent.

Z Image is Alibaba's fast image generation model with bilingual text rendering in Chinese and English. Hermes Agent calls it through the RunAPI custom provider endpoint — the same base_url and API key you use for chat, no extra plugins or GPU rentals needed.

one API key · text to image endpoint · async task polling
Use the RunAPI text_to_image endpoint to generate an image with Z Image.

Requirements:
- Use the RUNAPI_API_KEY environment variable for authentication.
- Send a POST request to https://runapi.ai/v1/text_to_image.
- Set model to "z-image".
- Write a descriptive prompt for the image you want to generate.
- The response returns a task_id. Poll the task status endpoint until the task completes, then retrieve the image URL from the output.
- Use the custom:runapi provider configured in your Hermes Agent config.yaml.
curl -X POST https://runapi.ai/v1/text_to_image \
  -H "Authorization: Bearer $RUNAPI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "z-image",
    "prompt": "A neon-lit Tokyo street at night with Japanese shop signs, cinematic lighting, 8K detail"
  }'
{
  "task_id": "tsk_abc123",
  "status": "pending",
  "model": "z-image"
}
Copy the curl command to test z-image
HOW IT WORKS

Use Z Image in Hermes Agent in three steps

1

Configure RunAPI

Set your RunAPI API key as an environment variable. If you already configured RunAPI as a custom provider in Hermes Agent, the same key and base_url work for image generation.

export RUNAPI_API_KEY=runapi_xxx
2

Call Z Image

Send a POST request to the text_to_image endpoint with model set to z-image and a text prompt. Z Image supports both Chinese and English prompts with accurate text rendering.

text_to_image
3

Get the result

The API returns a task_id immediately. Poll the task status endpoint until the status changes to completed, then retrieve the generated image URL from the response output.

task_id: tsk_abc123
PARAMETERS

Z Image API parameters

Parameter Type Description
model string Required. Use z-image.
prompt string Text description. Supports Chinese and English.
negative_prompt string Optional. What to avoid in the image.
size string Optional. Output dimensions, e.g. 1024x1024.

What is Z Image on Hermes Agent?

Z Image delivers what users describe as "insane speed and realism" -- it generates photorealistic images in under a second with strong prompt adherence and accurate facial details. Built on Apache 2.0 open source weights, it is both the fastest and cheapest image model on RunAPI at around $0.004 per image. Hermes Agent calls it through the same custom provider used for chat.

Z Image use cases

Storyboarding for film and animation

Generate storyboard frames at sub-second speed, iterating on compositions and camera angles fast enough to keep up with creative discussions in real time.

E-commerce product visualization

Generate product listing images with realistic materials and lighting at the lowest cost per image on RunAPI, suitable for high-volume catalog generation.

Educational illustrations

Create educational diagrams and illustrations with bilingual text labels, useful for textbooks, course materials, and training content targeting Chinese and English audiences.

FAQ

Z Image + Hermes Agent questions

Hermes Agent general setup

Not configured yet? Start with the RunAPI setup guide for Hermes Agent.

Hermes Agent setup guide →

Z Image model catalog

See all Z Image variants, pricing, and API docs.

Z Image models →

Try Z Image in Hermes Agent today.

Get a free RunAPI key, configure the custom provider, and start generating images with bilingual text rendering.