# ZimageGenerateRequest

## OpenAPI Specification

```yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths: {}
components:
  schemas:
    ZimageGenerateRequest:
      type: object
      additionalProperties: false
      required:
        - prompt
      properties:
        prompt:
          type: string
          description: Positive text prompt describing the desired image.
          minLength: 1
          maxLength: 2000
          examples:
            - >-
              a serene mountain landscape at sunset, photorealistic, 8k uhd,
              golden hour lighting
        negative_prompt:
          type: string
          description: Negative prompt describing what to avoid in the image.
          maxLength: 1000
          examples:
            - >-
              blurry, distorted, low quality, watermark, text, cropped, out of
              frame
        seed:
          type: integer
          description: Random seed for reproducible generation.
          minimum: 0
          maximum: 2147483647
          examples:
            - 42
        steps:
          type: integer
          description: Number of diffusion steps (max 30).
          minimum: 1
          maximum: 30
          default: 4
          examples:
            - 4
        cfg_scale:
          type: number
          description: Classifier-free guidance scale (recommended 0.0 for Z-Image Turbo).
          minimum: 0
          maximum: 20
          default: 0
          examples:
            - 0
        width:
          type: integer
          description: Output image width in pixels (divisible by 8, max 1024).
          minimum: 64
          maximum: 1024
          multipleOf: 8
          default: 512
          examples:
            - 512
        height:
          type: integer
          description: Output image height in pixels (divisible by 8, max 1024).
          minimum: 64
          maximum: 1024
          multipleOf: 8
          default: 512
          examples:
            - 512
        sampler:
          type: string
          description: Sampler algorithm name (if supported by backend).
          examples:
            - euler
        scheduler:
          type: string
          description: Scheduler name (if supported by backend).
          examples:
            - karras
        prompt_upsampling:
          type: boolean
          description: Enable AI-powered prompt enhancement (costs extra credits).
          default: false
          examples:
            - false
        webhookOverride:
          type: string
          format: uri
          description: Webhook URL to receive generation completion notifications.
          examples:
            - https://your-domain.com/webhook/zimage
        'n':
          type: integer
          description: Number of images to generate (currently fixed to 1).
          minimum: 1
          maximum: 1
          default: 1
          examples:
            - 1
        timeout:
          type: integer
          description: Maximum time (seconds) to wait for completion.
          minimum: 30
          maximum: 600
          default: 300
          examples:
            - 300
        ref:
          type: string
          description: Reference identifier for tracking.
          examples:
            - my-client-job-123
      x-apifox-orders:
        - prompt
        - negative_prompt
        - seed
        - steps
        - cfg_scale
        - width
        - height
        - sampler
        - scheduler
        - prompt_upsampling
        - webhookOverride
        - 'n'
        - timeout
        - ref
      x-apifox-folder: ''
  securitySchemes: {}
servers:
  - url: https://api.imaginepro.ai
    description: Prod Env
security: []

```
