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

# Wan 2.7 · Text to image

> Wan 2.7 text-to-image generation with strong prompt adherence.

[← Wan](/api-documentation/ai-generation/models/wan)

**Model name:** `wan2.7-image/text-to-image`\
**Generation type:** `text_to_image`\
**Endpoint:** [`POST /api/asset_generator/`](/api-reference/ai-generation/post-ai-generation)

## Pricing

**0.5** credits per output.

Prices are per output. When a request asks for several outputs, the charge is this price times the number of outputs.

## Quick start

<CodeGroup>
  ```bash cURL theme={null}
  curl --request POST \
    --url https://api.creatify.ai/api/asset_generator/ \
    --header 'Content-Type: application/json' \
    --header 'X-API-ID: your-api-id' \
    --header 'X-API-KEY: your-api-key' \
    --data '{
      "model_name": "wan2.7-image/text-to-image",
      "input_params": {
        "prompt": "A product photo of a ceramic mug on a marble counter, soft daylight."
      }
    }'
  ```

  ```python Python theme={null}
  import requests

  response = requests.post(
      "https://api.creatify.ai/api/asset_generator/",
      headers={"X-API-ID": "your-api-id", "X-API-KEY": "your-api-key"},
      json={
          "model_name": "wan2.7-image/text-to-image",
          "input_params": {
              "prompt": "A product photo of a ceramic mug on a marble counter, soft daylight."
          },
      },
  )
  print(response.json()["id"])
  ```
</CodeGroup>

## Input parameters

Send these fields in `input_params`.

<ParamField body="prompt" type="string" required>
  Describe the image you want to generate. Supports Chinese and English.

  Minimum characters: `1`.
  Maximum characters: `5000`.
</ParamField>

<ParamField body="aspect_ratio" type="string" default={"1:1"}>
  Aspect ratio of the generated image.

  Allowed values: `"1:1"`, `"16:9"`, `"9:16"`, `"4:3"`, `"3:4"`.
</ParamField>

<ParamField body="resolution" type="string" default={"2K"}>
  Resolution tier of the generated image.

  Allowed values: `"1K"`, `"2K"`.
</ParamField>

<ParamField body="num_images" type="integer" default={1}>
  Number of images to generate.

  Minimum: `1`.
  Maximum: `4`.
</ParamField>

<ParamField body="thinking_mode" type="boolean" default={true}>
  Use LLM reasoning to improve image quality.
</ParamField>

<ParamField body="seed" type="integer">
  Random seed for reproducibility.

  Minimum: `0`.
  Maximum: `2147483647`.
</ParamField>

<Accordion title="Complete JSON schema">
  ```json theme={null}
  {
    "$schema": "http://json-schema.org/draft-07/schema#",
    "required": [
      "prompt"
    ],
    "properties": {
      "prompt": {
        "type": "string",
        "title": "Prompt",
        "minLength": 1,
        "maxLength": 5000,
        "description": "Describe the image you want to generate. Supports Chinese and English."
      },
      "aspect_ratio": {
        "enum": [
          "1:1",
          "16:9",
          "9:16",
          "4:3",
          "3:4"
        ],
        "type": "string",
        "title": "Aspect Ratio",
        "default": "1:1",
        "description": "Aspect ratio of the generated image."
      },
      "resolution": {
        "enum": [
          "1K",
          "2K"
        ],
        "type": "string",
        "title": "Resolution",
        "default": "2K",
        "description": "Resolution tier of the generated image.",
        "x-advance-settings": true
      },
      "num_images": {
        "type": "integer",
        "title": "Number of Images",
        "default": 1,
        "maximum": 4,
        "minimum": 1,
        "x-ui-name": "output_nums",
        "description": "Number of images to generate."
      },
      "thinking_mode": {
        "type": "boolean",
        "title": "Thinking Mode",
        "default": true,
        "description": "Use LLM reasoning to improve image quality.",
        "x-advance-settings": true
      },
      "seed": {
        "type": "integer",
        "minimum": 0,
        "maximum": 2147483647,
        "title": "Seed",
        "description": "Random seed for reproducibility.",
        "x-advance-settings": true
      }
    }
  }
  ```
</Accordion>

## Response

The request returns the task with `status: "initializing"`. Poll [GET /api/asset\_generator/\{id}/](/api-reference/ai-generation/get-ai-generation-) until `status` is `done` or `failed`, or pass a `webhook_url` to be notified. A finished task lists its files in `assets` and the credits it charged in `credits_used`.


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