> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cassidyai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Generate image

> Generate an image from a text description using AI within a Workflow.

Generate AI images from text descriptions directly within a [Workflow](https://docs.cassidyai.com/workflows/overview.md). Use this to create visuals for content, social media, presentations, or any automation that needs image assets. The output is a file reference that can be used in subsequent Workflow actions, saved to your [Knowledge Base](https://docs.cassidyai.com/knowledge-base/overview.md), or sent via email or other integrations.

**1. Add the action**

In the Workflow builder, click **+** between blocks and select **Generate Image** from the action library.

![Action library with Generate Image selected](https://mintcdn.com/cassidy/fc5hlF9ZiEenavsC/images/reference/generate-image-img-0.png?fit=max\&auto=format\&n=fc5hlF9ZiEenavsC\&q=85\&s=89b54ebf8a7233d61a84ea7c7d8b952b)

**2. Write the image prompt**

In the **Prompt** field, describe the image you want to generate. Be specific about key elements, composition, lighting, mood, style, and colors for best results. [Reference variables](https://docs.cassidyai.com/guides/prompt-engineering.md#workflow-prompts) from previous steps or the trigger using **#** to create dynamic image prompts.

![Image prompt field with a detailed description](https://mintcdn.com/cassidy/PSOwom-PV6-w07rd/images/reference/generate-image-img-6.png?fit=max\&auto=format\&n=PSOwom-PV6-w07rd\&q=85\&s=1d79bb72e9f85f45bb8a5aa63605fbbc)

**3. Enter a file name**

In the **File Name** field, specify the name for the generated image file. You can reference variables from previous steps to create dynamic file names.

![File name field for the generated image](https://mintcdn.com/cassidy/PSOwom-PV6-w07rd/images/reference/generate-image-img-7.png?fit=max\&auto=format\&n=PSOwom-PV6-w07rd\&q=85\&s=0fe28c7a342734bde24b5f894dfe7af3)

**4. Choose the image quality**

In the **Quality** dropdown, select how Cassidy balances generation speed and visual precision:

* **Standard** (default) — balances visual quality and generation speed for most requests
* **High** — prioritizes visual precision and may take longer to generate

![Quality dropdown showing Standard and High image quality options](https://mintcdn.com/cassidy/fc5hlF9ZiEenavsC/images/reference/generate-image-img-quality.png?fit=max\&auto=format\&n=fc5hlF9ZiEenavsC\&q=85\&s=2dc66b3897ccb3b26a1fc19ee8363bd7)

**5. Choose the image size**

In the **Size** dropdown, select the aspect ratio for the generated image:

* **Auto** (default) — automatically determines the best aspect ratio based on your prompt
* **Square** — 1:1 aspect ratio
* **Portrait** — vertical orientation
* **Landscape** — horizontal orientation

![Size dropdown showing Auto, Square, Portrait, and Landscape options](https://mintcdn.com/cassidy/PSOwom-PV6-w07rd/images/reference/generate-image-img-8.png?fit=max\&auto=format\&n=PSOwom-PV6-w07rd\&q=85\&s=da849f93251577421683f30484d6f726)

**6. Select the background type**

In the **Background** dropdown, select the background type for the generated image:

* **Auto** (default) — AI determines the best background
* **Transparent** — generates an image with a transparent background
* **Opaque** — generates an image with a solid background

![Background dropdown showing Auto, Transparent, and Opaque options](https://mintcdn.com/cassidy/PSOwom-PV6-w07rd/images/reference/generate-image-img-9.png?fit=max\&auto=format\&n=PSOwom-PV6-w07rd\&q=85\&s=fb6d7fe4fe2de630d3f40789a614de28)

**7. Test the action**

Run a test of your Workflow to preview the generated image and ensure it meets your expectations. Refine your prompt based on the results to achieve the desired output.

![Test run showing the generated image preview](https://mintcdn.com/cassidy/PSOwom-PV6-w07rd/images/reference/generate-image-img-10.png?fit=max\&auto=format\&n=PSOwom-PV6-w07rd\&q=85\&s=b3e976bdb0ec9f34023ecbfe8633cee4)

## Related

* [Image Generation capability for Agents](https://docs.cassidyai.com/agents/capabilities/image-generation.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.