Skip to main content
The Image Generation action lets your Agents create images from text prompts. The model can also edit an image the user attached, or one it generated earlier in the conversation, instead of generating a new one from scratch. Once an admin connects an image model and sets it as the default, any chat model in Onyx can invoke the action.

Supported Models

OpenAI retired GPT Image 1 and Google retired Gemini 3 Pro Image Preview. Onyx hides these models unless they are already connected. If one of them is still connected, the page shows a warning. Connect another model, set it as the default, then disconnect the retired model.

Configuration

1

Connect a Model

Open Admin Panel → Image Generation and click Connect on a model. Enter the provider credentials:Image Generation page in the Onyx Admin Panel
  • API Key: Your OpenAI API key.
Onyx tests the credentials before it saves them.
2

Set the Default Model

Click Set as Default on the model you want to use. Only one model can be the default.
  • To clear the default, click the Current Default badge. Image generation is turned off until you set another default.
  • If you disconnect the current default model, the dialog asks you to choose a replacement default or No Default, which turns image generation off.

Enable Image Generation for Agents

Image generation does not appear in chat until a default model is set, even if an Agent has the action turned on.
  • Default Chat: Go to Admin Panel > Chat Preferences > Actions & Tools and turn on Image Generation.
  • Custom Agents: In the Agent editor, open Actions and turn on Image Generation. The toggle stays disabled until an admin connects a model.

Using Image Generation

When a user asks for an image, the Agent calls the default image model with a prompt it writes from the request. Generated images belong to the chat session that created them. To edit an image, the user attaches it to the message (or refers to an image generated earlier in the chat) and describes the change. The OpenAI and Azure OpenAI models accept up to 16 reference images; the Vertex AI models accept up to 14.