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

# 获取任务状态

> 查询编辑图片的任务结果，**该接口不消耗quota，免费使用**



## OpenAPI

````yaml openapi/cn/midjourneyedit.json get /midjourney/image-edits/fetch
openapi: 3.1.0
info:
  title: Midjourney Edit API DOCS
  version: 1.0.0
  description: Midjourney 图片修改相关接口
servers:
  - url: https://api.ttapi.io
security: []
paths:
  /midjourney/image-edits/fetch:
    get:
      description: 查询编辑图片的任务结果，**该接口不消耗quota，免费使用**
      parameters:
        - name: jobId
          in: query
          required: true
          schema:
            type: string
          description: 生成接口同步返回的jobId
      responses:
        '200':
          description: 请求成功
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - PENDING_QUEUE
                      - ON_QUEUE
                      - SUCCESS
                      - FAILED
                    description: 任务状态：PENDING_QUEUE-排队中，ON_QUEUE-处理中，SUCCESS-成功，FAILED-失败
                    example: SUCCESS
                  message:
                    type: string
                    description: 响应信息：成功时为空字符串，失败时返回具体错误原因（如「额度不足」「提示词违规」）
                    example: ''
                  jobId:
                    type: string
                    description: 任务唯一标识ID，用于查询任务状态/接收回调通知
                    example: c679a92e-dae0-462d-b70f-dcfeaf2189fa
                  data:
                    title: SUCCESS
                    type: object
                    description: 任务成功返回数据
                    properties:
                      jobId:
                        type: string
                        description: 任务id
                      progress:
                        type: string
                        description: 任务进度
                      mode:
                        type: string
                        description: 速度模式
                      prompt:
                        type: string
                        description: 提示词
                      quota:
                        type: string
                        description: 消耗配额
                      images:
                        type: string
                        description: 官方图像链接。有效期详见[存储与持久化](/grids/cn/faq/storage)
                      cdnImages:
                        type: string
                        description: cdn 图像链接。有效期详见[存储与持久化](/grids/cn/faq/storage)
                      hookUrl:
                        type: string
                        description: 回调地址
                      submitTime:
                        type: string
                        description: 提交时间
                        example: '2025-07-30T05:40:01Z'
                      finishTime:
                        type: string
                        description: 完成时间
                        example: '2025-07-30T05:40:01Z'
                    example:
                      jobId: d47481e2-f50d-43d4-aab9-231b0ca24ede
                      progress: '100'
                      mode: fast
                      prompt: >-
                        Workshop, 2D anime style, top-down perspective --niji 6
                        --s 100
                      quota: '4'
                      images:
                        - >-
                          https://cdn.midjourney.com/ca3259ad-ff76-4767-9d1c-e767776961bf/0_0.png
                        - >-
                          https://cdn.midjourney.com/ca3259ad-ff76-4767-9d1c-e767776961bf/0_1.png
                        - >-
                          https://cdn.midjourney.com/ca3259ad-ff76-4767-9d1c-e767776961bf/0_2.png
                        - >-
                          https://cdn.midjourney.com/ca3259ad-ff76-4767-9d1c-e767776961bf/0_3.png
                      cdnImages:
                        - >-
                          https://cdn.ttapi.io/midjourney/20260312/f1e98a48-df03-4033-b24c-fbb2ae5f7813tl.png
                        - >-
                          https://cdn.ttapi.io/midjourney/20260312/f1e98a48-df03-4033-b24c-fbb2ae5f7813tr.png
                        - >-
                          https://cdn.ttapi.io/midjourney/20260312/f1e98a48-df03-4033-b24c-fbb2ae5f7813bl.png
                        - >-
                          https://cdn.ttapi.io/midjourney/20260312/f1e98a48-df03-4033-b24c-fbb2ae5f7813br.png
                      hookUrl: null
                      submitTime: '2026-03-12T07:35:36Z'
                      finishTime: '2026-03-12T07:36:29Z'
                required:
                  - status
                  - message
                  - jobId
        '400':
          $ref: '#/components/responses/400Response'
        '401':
          $ref: '#/components/responses/401Response'
      security:
        - CustomApiKey: []
components:
  responses:
    400Response:
      description: 参数错误
      content:
        application/json:
          schema:
            type: object
            properties:
              status:
                type: string
                example: FAILED
              message:
                type: string
                example: '"prompt" cannot be empty.'
              data:
                type: object
            required:
              - status
              - message
    401Response:
      description: 授权失败
      content:
        application/json:
          schema:
            type: object
            properties:
              status:
                type: string
                example: FAILED
              message:
                type: string
                example: Wrong TT-API-KEY or email is not activated.
            required:
              - status
              - message
  securitySchemes:
    CustomApiKey:
      type: apiKey
      in: header
      name: TT-API-KEY
      description: >-
        请前往 <a href='https://dashboard.ttapi.io' target='_blank'>TTAPI 控制台</a>
        获取 API 密钥。

````