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

# Lucy Image 2

> Edit image from image using Lucy Image 2 model.



## OpenAPI

````yaml /openapi.json post /v1/generate/lucy-image-2
openapi: 3.1.0
info:
  title: Decart API
  version: 1.0.0
servers: []
security: []
paths:
  /v1/generate/lucy-image-2:
    post:
      summary: Lucy Image 2
      description: Edit image from image using Lucy Image 2 model.
      operationId: lucy_image_2_generate
      parameters:
        - name: x-api-key
          in: header
          required: true
          schema:
            type: string
            description: API key for authentication
            title: X-Api-Key
          description: API key for authentication
        - name: User-Agent
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: User-Agent
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              $ref: >-
                #/components/schemas/Body_generate_lucy_image_2_v1_generate_lucy_image_2_post
      responses:
        '200':
          description: Successful Response
          content:
            image/png:
              schema:
                type: string
                format: binary
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    Body_generate_lucy_image_2_v1_generate_lucy_image_2_post:
      properties:
        prompt:
          type: string
          title: Prompt
          description: Text prompt for the image generation
        data:
          type: string
          contentMediaType: application/octet-stream
          format: binary
          title: Data
          description: Image file to process
        reference_image:
          anyOf:
            - type: string
              contentMediaType: application/octet-stream
              format: binary
            - type: 'null'
          title: Reference Image
          description: Reference image file (optional)
        seed:
          type: integer
          maximum: 4294967295
          minimum: 0
          title: Seed
          description: Seed for the image generation
        resolution:
          type: string
          enum:
            - 720p
            - 480p
          title: Resolution
          description: Resolution of the image generation
          default: 720p
        enhance_prompt:
          type: boolean
          title: Enhance Prompt
          description: Whether to enhance the prompt
          default: true
      type: object
      required:
        - prompt
        - data
      title: Body_generate_lucy_image_2_v1_generate_lucy_image_2_post
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````