{
  "openapi": "3.0.3",
  "info": {
    "title": "矢量转换 API",
    "version": "0.1.0",
    "description": "异步图片转 SVG API。公开入口与网站同域名，使用独立 API Key。服务开放状态以 /capabilities 为准，当前不提供在线支付、官方 SDK 或同步直接返回 SVG 的接口。"
  },
  "servers": [
    {
      "url": "/openapi/v1",
      "description": "相对于当前站点来源；导入客户端工具时配置完整站点来源。"
    }
  ],
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "tags": [
    {
      "name": "任务"
    },
    {
      "name": "账户与能力"
    }
  ],
  "paths": {
    "/tasks": {
      "post": {
        "operationId": "createTask",
        "summary": "提交转换任务",
        "description": "上传一张图片，或使用 JSON 提交 imageUrl，创建异步转换任务并预留额度。同账户不同 Key 使用同一幂等键，仍对应同一任务。\n\n文件上传与 JSON imageUrl 二选一。URL 仅 HTTPS 443，无登录凭证，不跟随跳转；支持 COS/OSS 临时签名链接。同一幂等键必须保持原链接（含签名参数），已保存的图片副本会复用。不手动设置 multipart 的 Content-Type 或 boundary，由 HTTP 客户端生成。只返回 taskId 等状态信息，不直接返回 SVG。",
        "tags": [
          "任务"
        ],
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "x-required-scopes": [
          "tasks:write"
        ],
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": true,
            "description": "1–80 个 ASCII 字符：[A-Za-z0-9:_-]。每个逻辑任务唯一，原任务重试保留原键。",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 80,
              "pattern": "^[A-Za-z0-9:_-]+$"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "imageUrl"
                ],
                "additionalProperties": false,
                "properties": {
                  "imageUrl": {
                    "type": "string",
                    "format": "uri",
                    "maxLength": 8192,
                    "description": "HTTPS 图片直链或 COS/OSS 临时签名链接；仅 443，不跟随跳转。"
                  }
                }
              }
            },
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "required": [
                  "image"
                ],
                "additionalProperties": false,
                "properties": {
                  "image": {
                    "type": "string",
                    "format": "binary",
                    "description": "PNG/JPEG/WebP 单文件，最大 10 MiB、2,000 万像素。"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "202 接受新任务；200 返回幂等键对应的原任务。两者均返回 Task JSON。",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Task"
                },
                "example": {
                  "taskId": "6dd39862-bec8-44e4-b72e-50a40618ba6e",
                  "status": "queued",
                  "errorCode": null,
                  "createdAt": "2026-10-28T02:00:00.000Z",
                  "finishedAt": null,
                  "expiresAt": null,
                  "billing": {
                    "source": "package",
                    "state": "reserved",
                    "reservedCents": 0,
                    "chargedCents": null,
                    "successOrdinal": null
                  }
                }
              }
            },
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            }
          },
          "202": {
            "description": "新任务已接受并预留额度，尚未完成转换。",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Task"
                },
                "example": {
                  "taskId": "6dd39862-bec8-44e4-b72e-50a40618ba6e",
                  "status": "queued",
                  "errorCode": null,
                  "createdAt": "2026-10-28T02:00:00.000Z",
                  "finishedAt": null,
                  "expiresAt": null,
                  "billing": {
                    "source": "package",
                    "state": "reserved",
                    "reservedCents": 0,
                    "chargedCents": null,
                    "successOrdinal": null
                  }
                }
              }
            },
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            }
          },
          "400": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "402": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              },
              "Retry-After": {
                "description": "等待秒数，当前通常为 60。",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "503": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "default": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/tasks/{taskId}": {
      "get": {
        "operationId": "getTask",
        "summary": "查询任务",
        "description": "获取原任务的最新状态、结果领取截止时间及预留/结算信息。\n\n建议每 2–3 秒轮询一次，达到终态即停止。reconciling 时继续查原任务，不能据此新建替代任务。",
        "tags": [
          "任务"
        ],
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "x-required-scopes": [
          "tasks:read"
        ],
        "parameters": [
          {
            "name": "taskId",
            "in": "path",
            "required": true,
            "description": "提交接口返回的 taskId。",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "200 · Task JSON",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Task"
                },
                "example": {
                  "taskId": "6dd39862-bec8-44e4-b72e-50a40618ba6e",
                  "status": "succeeded",
                  "errorCode": null,
                  "createdAt": "2026-10-28T02:00:00.000Z",
                  "finishedAt": "2026-10-28T02:01:00.000Z",
                  "expiresAt": "2026-10-29T02:01:00.000Z",
                  "billing": {
                    "source": "package",
                    "state": "consumed",
                    "reservedCents": 0,
                    "chargedCents": 0,
                    "successOrdinal": "1"
                  }
                }
              }
            },
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            }
          },
          "401": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              },
              "Retry-After": {
                "description": "等待秒数，当前通常为 60。",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "503": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "default": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/tasks/{taskId}/result": {
      "get": {
        "operationId": "downloadResult",
        "summary": "下载结果",
        "description": "任务 succeeded 后鉴权领取 SVG。重复下载不增加成功次数或重复扣费。\n\n此响应不是 JSON。结果默认成功后保留 24 小时，以 Task.expiresAt 为准；410 表示已过期。",
        "tags": [
          "任务"
        ],
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "x-required-scopes": [
          "tasks:read"
        ],
        "parameters": [
          {
            "name": "taskId",
            "in": "path",
            "required": true,
            "description": "属于当前账户且已成功的任务编号。",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "200 · image/svg+xml 二进制内容，Content-Disposition: attachment",
            "content": {
              "image/svg+xml": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              }
            },
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              },
              "Content-Disposition": {
                "description": "SVG 下载文件名。",
                "schema": {
                  "type": "string",
                  "example": "attachment; filename=\"task-id.svg\""
                }
              }
            }
          },
          "401": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "410": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              },
              "Retry-After": {
                "description": "等待秒数，当前通常为 60。",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "503": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "default": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/tasks/{taskId}/cancel": {
      "post": {
        "operationId": "cancelTask",
        "summary": "申请取消任务",
        "description": "取消尚在排队的任务，或申请停止已经派发的任务。不需要 JSON 请求体。\n\n排队任务可直接变为 cancelled；已派发任务可能先变为 cancel_requested。成功与取消存在竞态，返回 succeeded 时仍按已完成结算。",
        "tags": [
          "任务"
        ],
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "x-required-scopes": [
          "tasks:write"
        ],
        "parameters": [
          {
            "name": "taskId",
            "in": "path",
            "required": true,
            "description": "当前账户任务编号。",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "200 · 最新 Task JSON",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Task"
                }
              }
            },
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            }
          },
          "401": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              },
              "Retry-After": {
                "description": "等待秒数，当前通常为 60。",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "503": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "default": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/account": {
      "get": {
        "operationId": "getAccount",
        "summary": "查看账户额度",
        "description": "查看余额、冻结额、可用次数包、历史成功次数与账户并发限制。\n\n余额及较大计数字段以十进制字符串返回。显示人民币金额时再除以 100，不使用浮点数做账。",
        "tags": [
          "账户与能力"
        ],
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "x-required-scopes": [
          "account:read"
        ],
        "responses": {
          "200": {
            "description": "200 · Account JSON",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Account"
                },
                "example": {
                  "accountId": "6fb13245-5c30-48e4-a5c7-0bfffc34a32f",
                  "currency": "CNY",
                  "balanceCents": "10000",
                  "reservedCents": "20",
                  "availableCents": "9980",
                  "packageAvailableCalls": "0",
                  "packageReservedCalls": "0",
                  "lifetimeSuccessCount": "999",
                  "nextUnitPriceCents": 20,
                  "maxConcurrency": 2,
                  "activeTasks": 1,
                  "maxPendingTasks": 20,
                  "walletFallback": true
                }
              }
            },
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            }
          },
          "401": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              },
              "Retry-After": {
                "description": "等待秒数，当前通常为 60。",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "503": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "default": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/usage": {
      "get": {
        "operationId": "getUsage",
        "summary": "查询成功结算记录",
        "description": "查询当前账户的成功调用记录，按历史成功序号升序返回，每页最多 100 条。\n\n只包含成功结算记录。排队、失败、恢复中的任务应通过 taskId 查询。chargedCents 单位为分，consumedPackageCalls 为包内次数。",
        "tags": [
          "账户与能力"
        ],
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "x-required-scopes": [
          "usage:read"
        ],
        "parameters": [
          {
            "name": "after",
            "in": "query",
            "required": false,
            "description": "可选，默认 0。不含起点，下一页传入上页 nextCursor；不支持任意日期筛选或 limit 参数。",
            "schema": {
              "type": "string",
              "pattern": "^[0-9]+$",
              "description": "十进制整数的字符串表示，避免客户端大整数精度丢失。",
              "default": "0",
              "maxLength": 19
            }
          }
        ],
        "responses": {
          "200": {
            "description": "200 · { items, nextCursor }；nextCursor 为 null 时本次已到末页。",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Usage"
                },
                "example": {
                  "items": [
                    {
                      "taskId": "6dd39862-bec8-44e4-b72e-50a40618ba6e",
                      "successOrdinal": "1001",
                      "source": "wallet",
                      "chargedCents": 15,
                      "consumedPackageCalls": 0,
                      "createdAt": "2026-10-28T02:01:00.000Z"
                    }
                  ],
                  "nextCursor": null
                }
              }
            },
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            }
          },
          "400": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              },
              "Retry-After": {
                "description": "等待秒数，当前通常为 60。",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "503": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "default": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/capabilities": {
      "get": {
        "operationId": "getCapabilities",
        "summary": "查询服务能力",
        "description": "接入前检查任务接收、支付能力、输入限制和结果保留时间。不产生转换费用。\n\nacceptsTasks=false 时不要新建任务。paymentAvailable=false 表示在线充值/购包尚未接通，不代表账户中的现有有效额度丢失。",
        "tags": [
          "账户与能力"
        ],
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "x-required-scopes": [],
        "responses": {
          "200": {
            "description": "200 · Capabilities JSON",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Capabilities"
                },
                "example": {
                  "version": "v1",
                  "acceptsTasks": false,
                  "paymentAvailable": false,
                  "formats": [
                    "png",
                    "jpeg",
                    "webp"
                  ],
                  "inputMethods": [
                    "multipart",
                    "https-url"
                  ],
                  "maxFileBytes": 10485760,
                  "maxInputPixels": 20000000,
                  "processingMaxEdge": 1200,
                  "maxConcurrency": 2,
                  "resultRetentionSeconds": 86400
                }
              }
            },
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            }
          },
          "401": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              },
              "Retry-After": {
                "description": "等待秒数，当前通常为 60。",
                "schema": {
                  "type": "string"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "503": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "default": {
            "description": "请求未成功；根据 HTTP 状态和 error.code 处理，不能把所有错误都当作可重试。",
            "headers": {
              "X-Request-Id": {
                "description": "单次应用请求编号；网关错误可能省略。",
                "schema": {
                  "type": "string"
                }
              },
              "Cache-Control": {
                "description": "带身份响应禁止公共缓存。",
                "schema": {
                  "type": "string",
                  "example": "no-store"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "description": "在控制台创建的 vk_live_ 开头 Key，仅在自有服务器保存。网站 Cookie 不是 API 调用凭证。"
      }
    },
    "schemas": {
      "Task": {
        "type": "object",
        "required": [
          "taskId",
          "status",
          "errorCode",
          "createdAt",
          "finishedAt",
          "expiresAt",
          "billing"
        ],
        "properties": {
          "taskId": {
            "type": "string",
            "format": "uuid"
          },
          "status": {
            "type": "string",
            "enum": [
              "queued",
              "dispatching",
              "running",
              "reconciling",
              "cancel_requested",
              "succeeded",
              "failed",
              "cancelled",
              "expired"
            ]
          },
          "errorCode": {
            "type": "string",
            "nullable": true
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "finishedAt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "expiresAt": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "billing": {
            "$ref": "#/components/schemas/Billing"
          }
        },
        "example": {
          "taskId": "6dd39862-bec8-44e4-b72e-50a40618ba6e",
          "status": "queued",
          "errorCode": null,
          "createdAt": "2026-10-28T02:00:00.000Z",
          "finishedAt": null,
          "expiresAt": null,
          "billing": {
            "source": "package",
            "state": "reserved",
            "reservedCents": 0,
            "chargedCents": null,
            "successOrdinal": null
          }
        }
      },
      "Billing": {
        "type": "object",
        "required": [
          "source",
          "state",
          "reservedCents",
          "chargedCents",
          "successOrdinal"
        ],
        "properties": {
          "source": {
            "type": "string",
            "enum": [
              "package",
              "wallet"
            ]
          },
          "state": {
            "type": "string",
            "enum": [
              "reserved",
              "consumed",
              "released"
            ]
          },
          "reservedCents": {
            "type": "integer",
            "minimum": 0,
            "description": "预留金额，单位分，次数包为 0。"
          },
          "chargedCents": {
            "type": "integer",
            "nullable": true,
            "minimum": 0,
            "description": "成功结算现金金额，单位分，次数包成功为 0，尚无成功结算为 null。"
          },
          "successOrdinal": {
            "type": "string",
            "pattern": "^[0-9]+$",
            "description": "十进制整数的字符串表示，避免客户端大整数精度丢失。",
            "nullable": true
          }
        }
      },
      "Account": {
        "type": "object",
        "required": [
          "accountId",
          "currency",
          "balanceCents",
          "reservedCents",
          "availableCents",
          "packageAvailableCalls",
          "packageReservedCalls",
          "lifetimeSuccessCount",
          "nextUnitPriceCents",
          "maxConcurrency",
          "activeTasks",
          "maxPendingTasks",
          "walletFallback"
        ],
        "properties": {
          "accountId": {
            "type": "string",
            "description": "当前 Key 所属的 API 计费账户。"
          },
          "currency": {
            "type": "string",
            "enum": [
              "CNY"
            ]
          },
          "balanceCents": {
            "type": "string",
            "pattern": "^[0-9]+$",
            "description": "余额总额，包含仍在预留的部分。"
          },
          "reservedCents": {
            "type": "string",
            "pattern": "^[0-9]+$",
            "description": "已被待处理任务预留的余额。"
          },
          "availableCents": {
            "type": "string",
            "pattern": "^[0-9]+$",
            "description": "当前可用余额，等于 balanceCents − reservedCents。"
          },
          "packageAvailableCalls": {
            "type": "string",
            "pattern": "^[0-9]+$",
            "description": "有效包中尚未消耗或预留的次数。"
          },
          "packageReservedCalls": {
            "type": "string",
            "pattern": "^[0-9]+$",
            "description": "已预留的包次数，包含仍在处理中的过期包预留。"
          },
          "lifetimeSuccessCount": {
            "type": "string",
            "pattern": "^[0-9]+$",
            "description": "历史成功调用总数，包内和余额调用共同累计，不按月重置。"
          },
          "nextUnitPriceCents": {
            "type": "integer",
            "description": "以当前历史次数计算的下一次余额调用单价，20 或 15 分。"
          },
          "maxConcurrency": {
            "type": "integer",
            "description": "账户执行并发上限，当前为 2，所有 Key 共享。"
          },
          "activeTasks": {
            "type": "integer",
            "description": "已经占用执行名额的任务数，包含恢复及取消确认中的任务。"
          },
          "maxPendingTasks": {
            "type": "integer",
            "description": "账户未结束任务上限，当前为 20。"
          },
          "walletFallback": {
            "type": "boolean",
            "description": "次数包耗尽后是否允许使用余额。"
          }
        },
        "example": {
          "accountId": "6fb13245-5c30-48e4-a5c7-0bfffc34a32f",
          "currency": "CNY",
          "balanceCents": "10000",
          "reservedCents": "20",
          "availableCents": "9980",
          "packageAvailableCalls": "0",
          "packageReservedCalls": "0",
          "lifetimeSuccessCount": "999",
          "nextUnitPriceCents": 20,
          "maxConcurrency": 2,
          "activeTasks": 1,
          "maxPendingTasks": 20,
          "walletFallback": true
        }
      },
      "UsageRecord": {
        "type": "object",
        "required": [
          "taskId",
          "successOrdinal",
          "source",
          "chargedCents",
          "consumedPackageCalls",
          "createdAt"
        ],
        "properties": {
          "taskId": {
            "type": "string",
            "format": "uuid"
          },
          "successOrdinal": {
            "type": "string",
            "pattern": "^[0-9]+$",
            "description": "十进制整数的字符串表示，避免客户端大整数精度丢失。"
          },
          "source": {
            "type": "string",
            "enum": [
              "wallet",
              "package"
            ]
          },
          "chargedCents": {
            "type": "integer",
            "minimum": 0
          },
          "consumedPackageCalls": {
            "type": "integer",
            "enum": [
              0,
              1
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "Usage": {
        "type": "object",
        "required": [
          "items",
          "nextCursor"
        ],
        "properties": {
          "items": {
            "type": "array",
            "maxItems": 100,
            "items": {
              "$ref": "#/components/schemas/UsageRecord"
            }
          },
          "nextCursor": {
            "type": "string",
            "pattern": "^[0-9]+$",
            "description": "十进制整数的字符串表示，避免客户端大整数精度丢失。",
            "nullable": true
          }
        },
        "example": {
          "items": [
            {
              "taskId": "6dd39862-bec8-44e4-b72e-50a40618ba6e",
              "successOrdinal": "1001",
              "source": "wallet",
              "chargedCents": 15,
              "consumedPackageCalls": 0,
              "createdAt": "2026-10-28T02:01:00.000Z"
            }
          ],
          "nextCursor": null
        }
      },
      "Capabilities": {
        "type": "object",
        "required": [
          "version",
          "acceptsTasks",
          "paymentAvailable",
          "formats",
          "inputMethods",
          "maxFileBytes",
          "maxInputPixels",
          "processingMaxEdge",
          "maxConcurrency",
          "resultRetentionSeconds"
        ],
        "properties": {
          "version": {
            "type": "string",
            "enum": [
              "v1"
            ]
          },
          "acceptsTasks": {
            "type": "boolean"
          },
          "paymentAvailable": {
            "type": "boolean"
          },
          "formats": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "png",
                "jpeg",
                "webp"
              ]
            }
          },
          "inputMethods": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "multipart",
                "https-url"
              ]
            }
          },
          "maxFileBytes": {
            "type": "integer"
          },
          "maxInputPixels": {
            "type": "integer"
          },
          "processingMaxEdge": {
            "type": "integer"
          },
          "maxConcurrency": {
            "type": "integer"
          },
          "resultRetentionSeconds": {
            "type": "integer"
          }
        },
        "example": {
          "version": "v1",
          "acceptsTasks": false,
          "paymentAvailable": false,
          "formats": [
            "png",
            "jpeg",
            "webp"
          ],
          "inputMethods": [
            "multipart",
            "https-url"
          ],
          "maxFileBytes": 10485760,
          "maxInputPixels": 20000000,
          "processingMaxEdge": 1200,
          "maxConcurrency": 2,
          "resultRetentionSeconds": 86400
        }
      },
      "Error": {
        "type": "object",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "object",
            "required": [
              "code"
            ],
            "properties": {
              "code": {
                "type": "string"
              }
            }
          },
          "requestId": {
            "type": "string",
            "description": "应用错误通常返回；网关错误可能省略。"
          }
        },
        "example": {
          "error": {
            "code": "API_CREDIT_INSUFFICIENT"
          },
          "requestId": "f7d692da-01bf-48c8-bb45-28d063b3d9d0"
        }
      }
    }
  }
}
